Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
linux
Commits
0115c1b6
Commit
0115c1b6
authored
Nov 23, 2007
by
Linus Torvalds
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Import 2.3.32pre1
parent
21279db0
Changes
15
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
15 changed files
with
250 additions
and
203 deletions
+250
-203
Makefile
Makefile
+1
-1
arch/i386/defconfig
arch/i386/defconfig
+7
-6
drivers/net/pcmcia/ray_cs.c
drivers/net/pcmcia/ray_cs.c
+26
-31
drivers/pcmcia/bulkmem.c
drivers/pcmcia/bulkmem.c
+13
-13
drivers/pcmcia/cb_enabler.c
drivers/pcmcia/cb_enabler.c
+11
-13
drivers/pcmcia/cistpl.c
drivers/pcmcia/cistpl.c
+18
-18
drivers/pcmcia/cs.c
drivers/pcmcia/cs.c
+84
-84
drivers/pcmcia/ds.c
drivers/pcmcia/ds.c
+28
-32
drivers/pcmcia/i82365.c
drivers/pcmcia/i82365.c
+1
-1
drivers/pcmcia/rsrc_mgr.c
drivers/pcmcia/rsrc_mgr.c
+1
-1
drivers/pcmcia/tcic.c
drivers/pcmcia/tcic.c
+1
-1
include/pcmcia/bulkmem.h
include/pcmcia/bulkmem.h
+12
-0
include/pcmcia/cistpl.h
include/pcmcia/cistpl.h
+8
-0
include/pcmcia/cs.h
include/pcmcia/cs.h
+36
-0
mm/memory.c
mm/memory.c
+3
-2
No files found.
Makefile
View file @
0115c1b6
VERSION
=
2
PATCHLEVEL
=
3
SUBLEVEL
=
3
1
SUBLEVEL
=
3
2
EXTRAVERSION
=
ARCH
:=
$(
shell
uname
-m
|
sed
-e
s/i.86/i386/
-e
s/sun4u/sparc64/
-e
s/arm.
*
/arm/
-e
s/sa110/arm/
)
...
...
arch/i386/defconfig
View file @
0115c1b6
...
...
@@ -306,6 +306,7 @@ CONFIG_PCMCIA_PCNET=y
# CONFIG_PCMCIA_NMCLAN is not set
# CONFIG_PCMCIA_SMC91C92 is not set
# CONFIG_PCMCIA_XIRC2PS is not set
# CONFIG_AIRONET4500_CS is not set
# CONFIG_PCMCIA_3C575 is not set
# CONFIG_PCMCIA_TULIP is not set
# CONFIG_PCMCIA_EPIC100 is not set
...
...
@@ -354,6 +355,11 @@ CONFIG_MOUSE=y
CONFIG_PSMOUSE=y
# CONFIG_82C710_MOUSE is not set
# CONFIG_PC110_PAD is not set
#
# Joysticks
#
# CONFIG_JOYSTICK is not set
# CONFIG_QIC02_TAPE is not set
#
...
...
@@ -367,11 +373,6 @@ CONFIG_PSMOUSE=y
# Video For Linux
#
# CONFIG_VIDEO_DEV is not set
#
# Joystick support
#
# CONFIG_JOYSTICK is not set
# CONFIG_DTLK is not set
# CONFIG_R3964 is not set
# CONFIG_APPLICOM is not set
...
...
@@ -409,7 +410,6 @@ CONFIG_AUTOFS_FS=y
# CONFIG_VFAT_FS is not set
CONFIG_ISO9660_FS=y
# CONFIG_JOLIET is not set
# CONFIG_UDF_FS is not set
# CONFIG_MINIX_FS is not set
# CONFIG_NTFS_FS is not set
# CONFIG_HPFS_FS is not set
...
...
@@ -418,6 +418,7 @@ CONFIG_DEVPTS_FS=y
# CONFIG_ROMFS_FS is not set
CONFIG_EXT2_FS=y
# CONFIG_SYSV_FS is not set
# CONFIG_UDF_FS is not set
# CONFIG_UFS_FS is not set
#
...
...
drivers/net/pcmcia/ray_cs.c
View file @
0115c1b6
...
...
@@ -312,8 +312,9 @@ static char rcsid[] = "Raylink/WebGear wireless LAN - Corey <Thomas corey@world.
static
void
cs_error
(
client_handle_t
handle
,
int
func
,
int
ret
)
{
error_info_t
err
=
{
func
,
ret
};
CardServices
(
ReportError
,
handle
,
&
err
);
pcmcia_report_error
(
handle
,
&
err
);
}
/*=============================================================================
ray_attach() creates an "instance" of the driver, allocating
local data structures for one device. The device is registered
...
...
@@ -409,7 +410,7 @@ static dev_link_t *ray_attach(void)
init_timer
(
&
local
->
timer
);
ret
=
CardServices
(
RegisterClient
,
&
link
->
handle
,
&
client_reg
);
ret
=
pcmcia_register_client
(
&
link
->
handle
,
&
client_reg
);
if
(
ret
!=
0
)
{
printk
(
"ray_cs ray_attach RegisterClient unhappy - detaching
\n
"
);
cs_error
(
link
->
handle
,
RegisterClient
,
ret
);
...
...
@@ -462,7 +463,7 @@ static void ray_detach(dev_link_t *link)
/* Break the link with Card Services */
if
(
link
->
handle
)
CardServices
(
DeregisterClient
,
link
->
handle
);
pcmcia_deregister_client
(
link
->
handle
);
/* Unlink device structure, free pieces */
*
linkp
=
link
->
next
;
...
...
@@ -482,14 +483,14 @@ static void ray_detach(dev_link_t *link)
ethernet device available to the system.
=============================================================================*/
#define CS_CHECK(fn, args...) \
while ((last_ret=
CardServices(last_fn=(fn),
args))!=0) goto cs_failed
while ((last_ret=
fn(
args))!=0) goto cs_failed
#define MAX_TUPLE_SIZE 128
static
void
ray_config
(
dev_link_t
*
link
)
{
client_handle_t
handle
=
link
->
handle
;
tuple_t
tuple
;
cisparse_t
parse
;
int
last_fn
,
last_ret
;
int
last_fn
=
0
,
last_ret
=
0
;
int
i
;
u_char
buf
[
MAX_TUPLE_SIZE
];
win_req_t
req
;
...
...
@@ -501,23 +502,23 @@ static void ray_config(dev_link_t *link)
/* This reads the card's CONFIG tuple to find its configuration regs */
tuple
.
DesiredTuple
=
CISTPL_CONFIG
;
CS_CHECK
(
GetFirstT
uple
,
handle
,
&
tuple
);
CS_CHECK
(
pcmcia_get_first_t
uple
,
handle
,
&
tuple
);
tuple
.
TupleData
=
buf
;
tuple
.
TupleDataMax
=
MAX_TUPLE_SIZE
;
tuple
.
TupleOffset
=
0
;
CS_CHECK
(
GetTupleD
ata
,
handle
,
&
tuple
);
CS_CHECK
(
ParseT
uple
,
handle
,
&
tuple
,
&
parse
);
CS_CHECK
(
pcmcia_get_tuple_d
ata
,
handle
,
&
tuple
);
CS_CHECK
(
pcmcia_parse_t
uple
,
handle
,
&
tuple
,
&
parse
);
link
->
conf
.
ConfigBase
=
parse
.
config
.
base
;
link
->
conf
.
Present
=
parse
.
config
.
rmask
[
0
];
/* Determine card type and firmware version */
buf
[
0
]
=
buf
[
MAX_TUPLE_SIZE
-
1
]
=
0
;
tuple
.
DesiredTuple
=
CISTPL_VERS_1
;
CS_CHECK
(
GetFirstT
uple
,
handle
,
&
tuple
);
CS_CHECK
(
pcmcia_get_first_t
uple
,
handle
,
&
tuple
);
tuple
.
TupleData
=
buf
;
tuple
.
TupleDataMax
=
MAX_TUPLE_SIZE
;
tuple
.
TupleOffset
=
2
;
CS_CHECK
(
GetTupleD
ata
,
handle
,
&
tuple
);
CS_CHECK
(
pcmcia_get_tuple_d
ata
,
handle
,
&
tuple
);
for
(
i
=
0
;
i
<
tuple
.
TupleDataLen
-
4
;
i
++
)
if
(
buf
[
i
]
==
0
)
buf
[
i
]
=
' '
;
...
...
@@ -529,13 +530,13 @@ static void ray_config(dev_link_t *link)
/* Now allocate an interrupt line. Note that this does not
actually assign a handler to the interrupt.
*/
CS_CHECK
(
RequestIRQ
,
link
->
handle
,
&
link
->
irq
);
CS_CHECK
(
pcmcia_request_irq
,
link
->
handle
,
&
link
->
irq
);
dev
->
irq
=
link
->
irq
.
AssignedIRQ
;
/* This actually configures the PCMCIA socket -- setting up
the I/O windows and the interrupt mapping.
*/
CS_CHECK
(
RequestC
onfiguration
,
link
->
handle
,
&
link
->
conf
);
CS_CHECK
(
pcmcia_request_c
onfiguration
,
link
->
handle
,
&
link
->
conf
);
/*** Set up 32k window for shared memory (transmit and control) ************/
req
.
Attributes
=
WIN_DATA_WIDTH_8
|
WIN_MEMORY_TYPE_CM
|
WIN_ENABLE
|
WIN_USE_WAIT
;
...
...
@@ -543,9 +544,9 @@ static void ray_config(dev_link_t *link)
req
.
Size
=
0x8000
;
req
.
AccessSpeed
=
ray_mem_speed
;
link
->
win
=
(
window_handle_t
)
link
->
handle
;
CS_CHECK
(
RequestW
indow
,
&
link
->
win
,
&
req
);
CS_CHECK
(
pcmcia_request_w
indow
,
&
link
->
win
,
&
req
);
mem
.
CardOffset
=
0x0000
;
mem
.
Page
=
0
;
CS_CHECK
(
MapMemP
age
,
link
->
win
,
&
mem
);
CS_CHECK
(
pcmcia_map_mem_p
age
,
link
->
win
,
&
mem
);
local
->
sram
=
(
UCHAR
*
)(
ioremap
(
req
.
Base
,
req
.
Size
));
/*** Set up 16k window for shared memory (receive buffer) ***************/
...
...
@@ -554,9 +555,9 @@ static void ray_config(dev_link_t *link)
req
.
Size
=
0x4000
;
req
.
AccessSpeed
=
ray_mem_speed
;
local
->
rmem_handle
=
(
window_handle_t
)
link
->
handle
;
CS_CHECK
(
RequestW
indow
,
&
local
->
rmem_handle
,
&
req
);
CS_CHECK
(
pcmcia_request_w
indow
,
&
local
->
rmem_handle
,
&
req
);
mem
.
CardOffset
=
0x8000
;
mem
.
Page
=
0
;
CS_CHECK
(
MapMemP
age
,
local
->
rmem_handle
,
&
mem
);
CS_CHECK
(
pcmcia_map_mem_p
age
,
local
->
rmem_handle
,
&
mem
);
local
->
rmem
=
(
UCHAR
*
)(
ioremap
(
req
.
Base
,
req
.
Size
));
/*** Set up window for attribute memory ***********************************/
...
...
@@ -565,9 +566,9 @@ static void ray_config(dev_link_t *link)
req
.
Size
=
0x1000
;
req
.
AccessSpeed
=
ray_mem_speed
;
local
->
amem_handle
=
(
window_handle_t
)
link
->
handle
;
CS_CHECK
(
RequestW
indow
,
&
local
->
amem_handle
,
&
req
);
CS_CHECK
(
pcmcia_request_w
indow
,
&
local
->
amem_handle
,
&
req
);
mem
.
CardOffset
=
0x0000
;
mem
.
Page
=
0
;
CS_CHECK
(
MapMemP
age
,
local
->
amem_handle
,
&
mem
);
CS_CHECK
(
pcmcia_map_mem_p
age
,
local
->
amem_handle
,
&
mem
);
local
->
amem
=
(
UCHAR
*
)(
ioremap
(
req
.
Base
,
req
.
Size
));
DEBUG
(
3
,
"ray_config sram=%p
\n
"
,
local
->
sram
);
...
...
@@ -893,15 +894,15 @@ static void ray_release(u_long arg)
iounmap
(
local
->
rmem
);
iounmap
(
local
->
amem
);
/* Do bother checking to see if these succeed or not */
i
=
CardServices
(
ReleaseWindow
,
link
->
win
);
i
=
pcmcia_release_window
(
link
->
win
);
if
(
i
!=
CS_SUCCESS
)
DEBUG
(
0
,
"ReleaseWindow(link->win) ret = %x
\n
"
,
i
);
i
=
CardServices
(
ReleaseWindow
,
local
->
amem_handle
);
i
=
pcmcia_release_window
(
local
->
amem_handle
);
if
(
i
!=
CS_SUCCESS
)
DEBUG
(
0
,
"ReleaseWindow(local->amem) ret = %x
\n
"
,
i
);
i
=
CardServices
(
ReleaseWindow
,
local
->
rmem_handle
);
i
=
pcmcia_release_window
(
local
->
rmem_handle
);
if
(
i
!=
CS_SUCCESS
)
DEBUG
(
0
,
"ReleaseWindow(local->rmem) ret = %x
\n
"
,
i
);
i
=
CardServices
(
ReleaseConfiguration
,
link
->
handle
);
i
=
pcmcia_release_configuration
(
link
->
handle
);
if
(
i
!=
CS_SUCCESS
)
DEBUG
(
0
,
"ReleaseConfiguration ret = %x
\n
"
,
i
);
i
=
CardServices
(
ReleaseIRQ
,
link
->
handle
,
&
link
->
irq
);
i
=
pcmcia_release_irq
(
link
->
handle
,
&
link
->
irq
);
if
(
i
!=
CS_SUCCESS
)
DEBUG
(
0
,
"ReleaseIRQ ret = %x
\n
"
,
i
);
link
->
state
&=
~
DEV_CONFIG
;
...
...
@@ -950,7 +951,7 @@ static int ray_event(event_t event, int priority,
dev
->
tbusy
=
1
;
dev
->
start
=
0
;
}
CardServices
(
ReleaseConfiguration
,
link
->
handle
);
pcmcia_release_configuration
(
link
->
handle
);
}
break
;
case
CS_EVENT_PM_RESUME
:
...
...
@@ -958,7 +959,7 @@ static int ray_event(event_t event, int priority,
/* Fall through... */
case
CS_EVENT_CARD_RESET
:
if
(
link
->
state
&
DEV_CONFIG
)
{
CardServices
(
RequestConfiguration
,
link
->
handle
,
&
link
->
conf
);
pcmcia_request_configuration
(
link
->
handle
,
&
link
->
conf
);
if
(
link
->
open
)
{
ray_reset
(
dev
);
dev
->
tbusy
=
0
;
...
...
@@ -2671,14 +2672,8 @@ static int build_auth_frame(ray_dev_t *local, UCHAR *dest, int auth_type)
static
int
__init
init_ray_cs
(
void
)
{
int
rc
;
servinfo_t
serv
;
DEBUG
(
1
,
"%s
\n
"
,
rcsid
);
CardServices
(
GetCardServicesInfo
,
&
serv
);
if
(
serv
.
Revision
!=
CS_RELEASE_CODE
)
{
printk
(
KERN_NOTICE
"ray: Card Services release does not match!
\n
"
);
return
-
1
;
}
rc
=
register_pcmcia_driver
(
&
dev_info
,
&
ray_attach
,
&
ray_detach
);
DEBUG
(
1
,
"raylink init_module register_pcmcia_driver returns 0x%x
\n
"
,
rc
);
#ifdef CONFIG_PROC_FS
...
...
drivers/pcmcia/bulkmem.c
View file @
0115c1b6
...
...
@@ -294,9 +294,9 @@ int MTDHelperEntry(int func, void *a1, void *a2)
{
switch
(
func
)
{
case
MTDRequestWindow
:
return
CardServices
(
RequestWindow
,
a1
,
a2
,
NULL
);
return
pcmcia_request_window
(
a1
,
a2
);
case
MTDReleaseWindow
:
return
CardServices
(
ReleaseWindow
,
a1
,
NULL
,
NULL
);
return
pcmcia_release_window
(
a1
);
case
MTDModifyWindow
:
return
mtd_modify_window
(
a1
,
a2
);
break
;
case
MTDSetVpp
:
...
...
@@ -403,7 +403,7 @@ static int match_region(client_handle_t handle, memory_handle_t list,
return
CS_NO_MORE_ITEMS
;
}
/* match_region */
int
get_first_region
(
client_handle_t
handle
,
region_info_t
*
rgn
)
int
pcmcia_
get_first_region
(
client_handle_t
handle
,
region_info_t
*
rgn
)
{
socket_info_t
*
s
=
SOCKET
(
handle
);
if
(
CHECK_HANDLE
(
handle
))
...
...
@@ -422,7 +422,7 @@ int get_first_region(client_handle_t handle, region_info_t *rgn)
return
match_region
(
handle
,
s
->
c_region
,
rgn
);
}
/* get_first_region */
int
get_next_region
(
client_handle_t
handle
,
region_info_t
*
rgn
)
int
pcmcia_
get_next_region
(
client_handle_t
handle
,
region_info_t
*
rgn
)
{
if
(
CHECK_HANDLE
(
handle
))
return
CS_BAD_HANDLE
;
...
...
@@ -435,7 +435,7 @@ int get_next_region(client_handle_t handle, region_info_t *rgn)
======================================================================*/
int
register_mtd
(
client_handle_t
handle
,
mtd_reg_t
*
reg
)
int
pcmcia_
register_mtd
(
client_handle_t
handle
,
mtd_reg_t
*
reg
)
{
memory_handle_t
list
;
socket_info_t
*
s
;
...
...
@@ -470,7 +470,7 @@ int register_mtd(client_handle_t handle, mtd_reg_t *reg)
======================================================================*/
int
register_erase_queue
(
client_handle_t
*
handle
,
eraseq_hdr_t
*
header
)
int
pcmcia_
register_erase_queue
(
client_handle_t
*
handle
,
eraseq_hdr_t
*
header
)
{
eraseq_t
*
queue
;
...
...
@@ -485,7 +485,7 @@ int register_erase_queue(client_handle_t *handle, eraseq_hdr_t *header)
return
CS_SUCCESS
;
}
/* register_erase_queue */
int
deregister_erase_queue
(
eraseq_handle_t
eraseq
)
int
pcmcia_
deregister_erase_queue
(
eraseq_handle_t
eraseq
)
{
int
i
;
if
(
CHECK_ERASEQ
(
eraseq
))
...
...
@@ -499,7 +499,7 @@ int deregister_erase_queue(eraseq_handle_t eraseq)
return
CS_SUCCESS
;
}
/* deregister_erase_queue */
int
check_erase_queue
(
eraseq_handle_t
eraseq
)
int
pcmcia_
check_erase_queue
(
eraseq_handle_t
eraseq
)
{
int
i
;
if
(
CHECK_ERASEQ
(
eraseq
))
...
...
@@ -517,7 +517,7 @@ int check_erase_queue(eraseq_handle_t eraseq)
======================================================================*/
int
open_memory
(
client_handle_t
*
handle
,
open_mem_t
*
open
)
int
pcmcia_
open_memory
(
client_handle_t
*
handle
,
open_mem_t
*
open
)
{
socket_info_t
*
s
;
memory_handle_t
region
;
...
...
@@ -550,7 +550,7 @@ int open_memory(client_handle_t *handle, open_mem_t *open)
======================================================================*/
int
close_memory
(
memory_handle_t
handle
)
int
pcmcia_
close_memory
(
memory_handle_t
handle
)
{
DEBUG
(
1
,
"cs: close_memory(0x%p)
\n
"
,
handle
);
if
(
CHECK_REGION
(
handle
))
...
...
@@ -565,7 +565,7 @@ int close_memory(memory_handle_t handle)
======================================================================*/
int
read_memory
(
memory_handle_t
handle
,
mem_op_t
*
req
,
caddr_t
buf
)
int
pcmcia_
read_memory
(
memory_handle_t
handle
,
mem_op_t
*
req
,
caddr_t
buf
)
{
mtd_request_t
mtd
;
if
(
CHECK_REGION
(
handle
))
...
...
@@ -591,7 +591,7 @@ int read_memory(memory_handle_t handle, mem_op_t *req, caddr_t buf)
======================================================================*/
int
write_memory
(
memory_handle_t
handle
,
mem_op_t
*
req
,
caddr_t
buf
)
int
pcmcia_
write_memory
(
memory_handle_t
handle
,
mem_op_t
*
req
,
caddr_t
buf
)
{
mtd_request_t
mtd
;
if
(
CHECK_REGION
(
handle
))
...
...
@@ -616,7 +616,7 @@ int write_memory(memory_handle_t handle, mem_op_t *req, caddr_t buf)
======================================================================*/
int
copy_memory
(
memory_handle_t
handle
,
copy_op_t
*
req
)
int
pcmcia_
copy_memory
(
memory_handle_t
handle
,
copy_op_t
*
req
)
{
if
(
CHECK_REGION
(
handle
))
return
CS_BAD_HANDLE
;
...
...
drivers/pcmcia/cb_enabler.c
View file @
0115c1b6
...
...
@@ -113,7 +113,7 @@ static bus_info_t bus_table[MAX_DRIVER];
static
void
cs_error
(
client_handle_t
handle
,
int
func
,
int
ret
)
{
error_info_t
err
=
{
func
,
ret
};
CardServices
(
ReportError
,
handle
,
&
err
);
pcmcia_report_error
(
handle
,
&
err
);
}
/*====================================================================*/
...
...
@@ -148,7 +148,7 @@ struct dev_link_t *cb_attach(int n)
CS_EVENT_PM_SUSPEND
|
CS_EVENT_PM_RESUME
;
client_reg
.
Version
=
0x0210
;
client_reg
.
event_callback_args
.
client_data
=
link
;
ret
=
CardServices
(
RegisterClient
,
&
link
->
handle
,
&
client_reg
);
ret
=
pcmcia_register_client
(
&
link
->
handle
,
&
client_reg
);
if
(
ret
!=
0
)
{
cs_error
(
link
->
handle
,
RegisterClient
,
ret
);
cb_detach
(
link
);
...
...
@@ -183,7 +183,7 @@ static void cb_detach(dev_link_t *link)
}
if
(
link
->
handle
)
CardServices
(
DeregisterClient
,
link
->
handle
);
pcmcia_deregister_client
(
link
->
handle
);
*
linkp
=
link
->
next
;
kfree_s
(
link
,
sizeof
(
struct
dev_link_t
));
...
...
@@ -206,7 +206,7 @@ static void cb_config(dev_link_t *link)
link
->
state
|=
DEV_CONFIG
;
/* Get PCI bus info */
CardServices
(
GetConfigurationInfo
,
handle
,
&
config
);
pcmcia_get_configuration_info
(
handle
,
&
config
);
bus
=
config
.
Option
;
devfn
=
config
.
Function
;
/* Is this a new bus? */
...
...
@@ -221,14 +221,14 @@ static void cb_config(dev_link_t *link)
b
->
ncfg
=
b
->
nuse
=
1
;
/* Special hook: CS know what to do... */
i
=
CardServices
(
RequestIO
,
handle
,
NULL
);
i
=
pcmcia_request_io
(
handle
,
NULL
);
if
(
i
!=
CS_SUCCESS
)
{
cs_error
(
handle
,
RequestIO
,
i
);
return
;
}
b
->
flags
|=
DID_REQUEST
;
b
->
owner
=
link
;
i
=
CardServices
(
RequestConfiguration
,
handle
,
&
link
->
conf
);
i
=
pcmcia_request_configuration
(
handle
,
&
link
->
conf
);
if
(
i
!=
CS_SUCCESS
)
{
cs_error
(
handle
,
RequestConfiguration
,
i
);
return
;
...
...
@@ -267,12 +267,11 @@ static void cb_release(u_long arg)
if
(
link
->
state
&
DEV_SUSPEND
)
b
->
flags
&=
~
DID_CONFIG
;
else
if
((
b
->
flags
&
DID_CONFIG
)
&&
(
--
b
->
ncfg
==
0
))
{
CardServices
(
ReleaseConfiguration
,
b
->
owner
->
handle
,
&
b
->
owner
->
conf
);
pcmcia_release_configuration
(
b
->
owner
->
handle
);
b
->
flags
&=
~
DID_CONFIG
;
}
if
((
b
->
flags
&
DID_REQUEST
)
&&
(
--
b
->
nuse
==
0
))
{
CardServices
(
ReleaseIO
,
b
->
owner
->
handle
,
NULL
);
pcmcia_release_io
(
b
->
owner
->
handle
,
NULL
);
b
->
flags
&=
~
DID_REQUEST
;
}
if
(
b
->
flags
==
0
)
{
...
...
@@ -314,8 +313,7 @@ static int cb_event(event_t event, int priority,
drv
->
ops
->
suspend
(
link
->
dev
);
b
->
ncfg
--
;
if
(
b
->
ncfg
==
0
)
CardServices
(
ReleaseConfiguration
,
link
->
handle
,
&
link
->
conf
);
pcmcia_release_configuration
(
link
->
handle
);
}
break
;
case
CS_EVENT_PM_RESUME
:
...
...
@@ -325,7 +323,7 @@ static int cb_event(event_t event, int priority,
if
(
link
->
state
&
DEV_CONFIG
)
{
b
->
ncfg
++
;
if
(
b
->
ncfg
==
1
)
CardServices
(
RequestConfiguration
,
link
->
handle
,
pcmcia_request_configuration
(
link
->
handle
,
&
link
->
conf
);
if
(
drv
->
ops
->
resume
!=
NULL
)
drv
->
ops
->
resume
(
link
->
dev
);
...
...
@@ -379,7 +377,7 @@ static int __init init_cb_enabler(void)
{
servinfo_t
serv
;
DEBUG
(
0
,
"%s
\n
"
,
version
);
CardServices
(
GetCardServicesInfo
,
&
serv
);
pcmcia_get_card_services_info
(
&
serv
);
if
(
serv
.
Revision
!=
CS_RELEASE_CODE
)
{
printk
(
KERN_NOTICE
"cb_enabler: Card Services release "
"does not match!
\n
"
);
...
...
drivers/pcmcia/cistpl.c
View file @
0115c1b6
...
...
@@ -158,7 +158,7 @@ static int cis_readable(u_long base)
vs
->
cis_mem
.
sys_start
=
base
;
vs
->
cis_mem
.
sys_stop
=
base
+
vs
->
cap
.
map_size
-
1
;
vs
->
cis_virt
=
bus_ioremap
(
vs
->
cap
.
bus
,
base
,
vs
->
cap
.
map_size
);
ret
=
validate_cis
(
vs
->
clients
,
&
info1
);
ret
=
pcmcia_
validate_cis
(
vs
->
clients
,
&
info1
);
/* invalidate mapping and CIS cache */
bus_iounmap
(
vs
->
cap
.
bus
,
vs
->
cis_virt
);
vs
->
cis_used
=
0
;
if
((
ret
!=
0
)
||
(
info1
.
Chains
==
0
))
...
...
@@ -167,7 +167,7 @@ static int cis_readable(u_long base)
vs
->
cis_mem
.
sys_stop
=
base
+
2
*
vs
->
cap
.
map_size
-
1
;
vs
->
cis_virt
=
bus_ioremap
(
vs
->
cap
.
bus
,
base
+
vs
->
cap
.
map_size
,
vs
->
cap
.
map_size
);
ret
=
validate_cis
(
vs
->
clients
,
&
info2
);
ret
=
pcmcia_
validate_cis
(
vs
->
clients
,
&
info2
);
bus_iounmap
(
vs
->
cap
.
bus
,
vs
->
cis_virt
);
vs
->
cis_used
=
0
;
return
((
ret
==
0
)
&&
(
info1
.
Chains
==
info2
.
Chains
));
}
...
...
@@ -315,7 +315,7 @@ int verify_cis_cache(socket_info_t *s)
======================================================================*/
int
replace_cis
(
client_handle_t
handle
,
cisdump_t
*
cis
)
int
pcmcia_
replace_cis
(
client_handle_t
handle
,
cisdump_t
*
cis
)
{
socket_info_t
*
s
;
if
(
CHECK_HANDLE
(
handle
))
...
...
@@ -353,9 +353,9 @@ typedef struct tuple_flags {
#define MFC_FN(f) (((tuple_flags *)(&(f)))->mfc_fn)
#define SPACE(f) (((tuple_flags *)(&(f)))->space)
int
get_next_tuple
(
client_handle_t
handle
,
tuple_t
*
tuple
);
int
pcmcia_
get_next_tuple
(
client_handle_t
handle
,
tuple_t
*
tuple
);
int
get_first_tuple
(
client_handle_t
handle
,
tuple_t
*
tuple
)
int
pcmcia_
get_first_tuple
(
client_handle_t
handle
,
tuple_t
*
tuple
)
{
socket_info_t
*
s
;
if
(
CHECK_HANDLE
(
handle
))
...
...
@@ -381,15 +381,15 @@ int get_first_tuple(client_handle_t handle, tuple_t *tuple)
!
(
tuple
->
Attributes
&
TUPLE_RETURN_COMMON
))
{
cisdata_t
req
=
tuple
->
DesiredTuple
;
tuple
->
DesiredTuple
=
CISTPL_LONGLINK_MFC
;
if
(
get_next_tuple
(
handle
,
tuple
)
==
CS_SUCCESS
)
{
if
(
pcmcia_
get_next_tuple
(
handle
,
tuple
)
==
CS_SUCCESS
)
{
tuple
->
DesiredTuple
=
CISTPL_LINKTARGET
;
if
(
get_next_tuple
(
handle
,
tuple
)
!=
CS_SUCCESS
)
if
(
pcmcia_
get_next_tuple
(
handle
,
tuple
)
!=
CS_SUCCESS
)
return
CS_NO_MORE_ITEMS
;
}
else
tuple
->
CISOffset
=
tuple
->
TupleLink
=
0
;
tuple
->
DesiredTuple
=
req
;
}
return
get_next_tuple
(
handle
,
tuple
);
return
pcmcia_
get_next_tuple
(
handle
,
tuple
);
}
static
int
follow_link
(
socket_info_t
*
s
,
tuple_t
*
tuple
)
...
...
@@ -430,7 +430,7 @@ static int follow_link(socket_info_t *s, tuple_t *tuple)
return
ofs
;
}
int
get_next_tuple
(
client_handle_t
handle
,
tuple_t
*
tuple
)
int
pcmcia_
get_next_tuple
(
client_handle_t
handle
,
tuple_t
*
tuple
)
{
socket_info_t
*
s
;
u_char
link
[
2
],
tmp
;
...
...
@@ -510,7 +510,7 @@ int get_next_tuple(client_handle_t handle, tuple_t *tuple)
ofs
+=
link
[
1
]
+
2
;
}
if
(
i
==
MAX_TUPLES
)
{
DEBUG
(
1
,
"cs: overrun in get_next_tuple for socket %d
\n
"
,
DEBUG
(
1
,
"cs: overrun in
pcmcia_
get_next_tuple for socket %d
\n
"
,
handle
->
Socket
);
return
CS_NO_MORE_ITEMS
;
}
...
...
@@ -525,7 +525,7 @@ int get_next_tuple(client_handle_t handle, tuple_t *tuple)
#define _MIN(a, b) (((a) < (b)) ? (a) : (b))
int
get_tuple_data
(
client_handle_t
handle
,
tuple_t
*
tuple
)
int
pcmcia_
get_tuple_data
(
client_handle_t
handle
,
tuple_t
*
tuple
)
{
socket_info_t
*
s
;
u_int
len
;
...
...
@@ -1234,7 +1234,7 @@ static int parse_org(tuple_t *tuple, cistpl_org_t *org)
/*====================================================================*/
int
parse_tuple
(
client_handle_t
handle
,
tuple_t
*
tuple
,
cisparse_t
*
parse
)
int
p
cmcia_p
arse_tuple
(
client_handle_t
handle
,
tuple_t
*
tuple
,
cisparse_t
*
parse
)
{
int
ret
=
CS_SUCCESS
;
...
...
@@ -1326,14 +1326,14 @@ int read_tuple(client_handle_t handle, cisdata_t code, void *parse)
tuple
.
DesiredTuple
=
code
;
tuple
.
Attributes
=
TUPLE_RETURN_COMMON
;
ret
=
CardServices
(
GetFirstTuple
,
handle
,
&
tuple
,
NULL
);
ret
=
pcmcia_get_first_tuple
(
handle
,
&
tuple
);
if
(
ret
!=
CS_SUCCESS
)
return
ret
;
tuple
.
TupleData
=
buf
;
tuple
.
TupleOffset
=
0
;
tuple
.
TupleDataMax
=
sizeof
(
buf
);
ret
=
CardServices
(
GetTupleData
,
handle
,
&
tuple
,
NULL
);
ret
=
pcmcia_get_tuple_data
(
handle
,
&
tuple
);
if
(
ret
!=
CS_SUCCESS
)
return
ret
;
ret
=
CardServices
(
ParseTuple
,
handle
,
&
tuple
,
parse
);
ret
=
pcmcia_parse_tuple
(
handle
,
&
tuple
,
parse
);
return
ret
;
}
...
...
@@ -1347,7 +1347,7 @@ int read_tuple(client_handle_t handle, cisdata_t code, void *parse)
======================================================================*/
int
validate_cis
(
client_handle_t
handle
,
cisinfo_t
*
info
)
int
pcmcia_
validate_cis
(
client_handle_t
handle
,
cisinfo_t
*
info
)
{
tuple_t
tuple
;
cisparse_t
p
;
...
...
@@ -1359,7 +1359,7 @@ int validate_cis(client_handle_t handle, cisinfo_t *info)
info
->
Chains
=
reserved
=
errors
=
0
;
tuple
.
DesiredTuple
=
RETURN_FIRST_TUPLE
;
tuple
.
Attributes
=
TUPLE_RETURN_COMMON
;
ret
=
get_first_tuple
(
handle
,
&
tuple
);
ret
=
pcmcia_
get_first_tuple
(
handle
,
&
tuple
);
if
(
ret
!=
CS_SUCCESS
)
return
CS_SUCCESS
;
...
...
@@ -1380,7 +1380,7 @@ int validate_cis(client_handle_t handle, cisinfo_t *info)
return
CS_SUCCESS
;
for
(
info
->
Chains
=
1
;
info
->
Chains
<
MAX_TUPLES
;
info
->
Chains
++
)
{
ret
=
get_next_tuple
(
handle
,
&
tuple
);
ret
=
pcmcia_
get_next_tuple
(
handle
,
&
tuple
);
if
(
ret
!=
CS_SUCCESS
)
break
;
if
(((
tuple
.
TupleCode
>
0x23
)
&&
(
tuple
.
TupleCode
<
0x40
))
||
((
tuple
.
TupleCode
>
0x47
)
&&
(
tuple
.
TupleCode
<
0x80
))
||
...
...
drivers/pcmcia/cs.c
View file @
0115c1b6
This diff is collapsed.
Click to expand it.
drivers/pcmcia/ds.c
View file @
0115c1b6
...
...
@@ -128,7 +128,7 @@ static int init_status = 1;
static
void
cs_error
(
client_handle_t
handle
,
int
func
,
int
ret
)
{
error_info_t
err
=
{
func
,
ret
};
CardServices
(
ReportError
,
handle
,
&
err
);
pcmcia_report_error
(
handle
,
&
err
);
}
/*======================================================================
...
...
@@ -340,7 +340,7 @@ static int bind_mtd(int i, mtd_info_t *mtd_info)
bind_req
.
Attributes
=
mtd_info
->
Attributes
;
bind_req
.
Socket
=
i
;
bind_req
.
CardOffset
=
mtd_info
->
CardOffset
;
ret
=
CardServices
(
BindMTD
,
&
bind_req
);
ret
=
pcmcia_bind_mtd
(
&
bind_req
);
if
(
ret
!=
CS_SUCCESS
)
{
cs_error
(
NULL
,
BindMTD
,
ret
);
printk
(
KERN_NOTICE
"ds: unable to bind MTD '%s' to socket %d"
...
...
@@ -394,7 +394,7 @@ static int bind_request(int i, bind_info_t *bind_info)
bind_req
.
Socket
=
i
;
bind_req
.
Function
=
bind_info
->
function
;
bind_req
.
dev_info
=
&
driver
->
dev_info
;
ret
=
CardServices
(
BindDevice
,
&
bind_req
);
ret
=
pcmcia_bind_device
(
&
bind_req
);
if
(
ret
!=
CS_SUCCESS
)
{
cs_error
(
NULL
,
BindDevice
,
ret
);
printk
(
KERN_NOTICE
"ds: unable to bind '%s' to socket %d
\n
"
,
...
...
@@ -687,78 +687,74 @@ static int ds_ioctl(struct inode * inode, struct file * file,
switch
(
cmd
)
{
case
DS_ADJUST_RESOURCE_INFO
:
ret
=
CardServices
(
AdjustResourceInfo
,
s
->
handle
,
&
buf
.
adjust
);
ret
=
pcmcia_adjust_resource_info
(
s
->
handle
,
&
buf
.
adjust
);
break
;
case
DS_GET_CARD_SERVICES_INFO
:
ret
=
CardServices
(
GetCardServicesInfo
,
&
buf
.
servinfo
);
ret
=
pcmcia_get_card_services_info
(
&
buf
.
servinfo
);
break
;
case
DS_GET_CONFIGURATION_INFO
:
ret
=
CardServices
(
GetConfigurationInfo
,
s
->
handle
,
&
buf
.
config
);
ret
=
pcmcia_get_configuration_info
(
s
->
handle
,
&
buf
.
config
);
break
;
case
DS_GET_FIRST_TUPLE
:
ret
=
CardServices
(
GetFirstTuple
,
s
->
handle
,
&
buf
.
tuple
);
ret
=
pcmcia_get_first_tuple
(
s
->
handle
,
&
buf
.
tuple
);
break
;
case
DS_GET_NEXT_TUPLE
:
ret
=
CardServices
(
GetNextTuple
,
s
->
handle
,
&
buf
.
tuple
);
ret
=
pcmcia_get_next_tuple
(
s
->
handle
,
&
buf
.
tuple
);
break
;
case
DS_GET_TUPLE_DATA
:
buf
.
tuple
.
TupleData
=
buf
.
tuple_parse
.
data
;
buf
.
tuple
.
TupleDataMax
=
sizeof
(
buf
.
tuple_parse
.
data
);
ret
=
CardServices
(
GetTupleData
,
s
->
handle
,
&
buf
.
tuple
);
ret
=
pcmcia_get_tuple_data
(
s
->
handle
,
&
buf
.
tuple
);
break
;
case
DS_PARSE_TUPLE
:
buf
.
tuple
.
TupleData
=
buf
.
tuple_parse
.
data
;
ret
=
CardServices
(
ParseTuple
,
s
->
handle
,
&
buf
.
tuple
,
&
buf
.
tuple_parse
.
parse
);
ret
=
pcmcia_parse_tuple
(
s
->
handle
,
&
buf
.
tuple
,
&
buf
.
tuple_parse
.
parse
);
break
;
case
DS_RESET_CARD
:
ret
=
CardServices
(
ResetCard
,
s
->
handle
,
NULL
);
ret
=
pcmcia_reset_card
(
s
->
handle
,
NULL
);
break
;
case
DS_GET_STATUS
:
ret
=
CardServices
(
GetStatus
,
s
->
handle
,
&
buf
.
status
);
ret
=
pcmcia_get_status
(
s
->
handle
,
&
buf
.
status
);
break
;
case
DS_VALIDATE_CIS
:
ret
=
CardServices
(
ValidateCIS
,
s
->
handle
,
&
buf
.
cisinfo
);
ret
=
pcmcia_validate_cis
(
s
->
handle
,
&
buf
.
cisinfo
);
break
;
case
DS_SUSPEND_CARD
:
ret
=
CardServices
(
SuspendCard
,
s
->
handle
,
NULL
);
ret
=
pcmcia_suspend_card
(
s
->
handle
,
NULL
);
break
;
case
DS_RESUME_CARD
:
ret
=
CardServices
(
ResumeCard
,
s
->
handle
,
NULL
);
ret
=
pcmcia_resume_card
(
s
->
handle
,
NULL
);
break
;
case
DS_EJECT_CARD
:
ret
=
CardServices
(
EjectCard
,
s
->
handle
,
NULL
);
ret
=
pcmcia_eject_card
(
s
->
handle
,
NULL
);
break
;
case
DS_INSERT_CARD
:
ret
=
CardServices
(
InsertCard
,
s
->
handle
,
NULL
);
ret
=
pcmcia_insert_card
(
s
->
handle
,
NULL
);
break
;
case
DS_ACCESS_CONFIGURATION_REGISTER
:
if
((
buf
.
conf_reg
.
Action
==
CS_WRITE
)
&&
!
suser
())
return
-
EPERM
;
ret
=
CardServices
(
AccessConfigurationRegister
,
s
->
handle
,
&
buf
.
conf_reg
);
ret
=
pcmcia_access_configuration_register
(
s
->
handle
,
&
buf
.
conf_reg
);
break
;
case
DS_GET_FIRST_REGION
:
ret
=
CardServices
(
GetFirstRegion
,
s
->
handle
,
&
buf
.
region
);
ret
=
pcmcia_get_first_region
(
s
->
handle
,
&
buf
.
region
);
break
;
case
DS_GET_NEXT_REGION
:
ret
=
CardServices
(
GetNextRegion
,
s
->
handle
,
&
buf
.
region
);
ret
=
pcmcia_get_next_region
(
s
->
handle
,
&
buf
.
region
);
break
;
case
DS_GET_FIRST_WINDOW
:
buf
.
win_info
.
handle
=
(
window_handle_t
)
s
->
handle
;
ret
=
CardServices
(
GetFirstWindow
,
&
buf
.
win_info
.
handle
,
&
buf
.
win_info
.
window
);
ret
=
pcmcia_get_first_window
(
&
buf
.
win_info
.
handle
,
&
buf
.
win_info
.
window
);
break
;
case
DS_GET_NEXT_WINDOW
:
ret
=
CardServices
(
GetNextWindow
,
&
buf
.
win_info
.
handle
,
&
buf
.
win_info
.
window
);
ret
=
pcmcia_get_next_window
(
&
buf
.
win_info
.
handle
,
&
buf
.
win_info
.
window
);
break
;
case
DS_GET_MEM_PAGE
:
ret
=
CardServices
(
GetMemPage
,
buf
.
win_info
.
handle
,
ret
=
pcmcia_get_mem_page
(
buf
.
win_info
.
handle
,
&
buf
.
win_info
.
map
);
break
;
case
DS_REPLACE_CIS
:
ret
=
CardServices
(
ReplaceCIS
,
s
->
handle
,
&
buf
.
cisdump
);
ret
=
pcmcia_replace_cis
(
s
->
handle
,
&
buf
.
cisdump
);
break
;
case
DS_BIND_REQUEST
:
if
(
!
suser
())
return
-
EPERM
;
...
...
@@ -838,7 +834,7 @@ int __init init_pcmcia_ds(void)
DEBUG
(
0
,
"%s
\n
"
,
version
);
CardServices
(
GetCardServicesInfo
,
&
serv
);
pcmcia_get_card_services_info
(
&
serv
);
if
(
serv
.
Revision
!=
CS_RELEASE_CODE
)
{
printk
(
KERN_NOTICE
"ds: Card Services release does not match!
\n
"
);
return
-
1
;
...
...
@@ -876,13 +872,13 @@ int __init init_pcmcia_ds(void)
for
(
i
=
0
;
i
<
sockets
;
i
++
)
{
bind
.
Socket
=
i
;
bind
.
Function
=
BIND_FN_ALL
;
ret
=
CardServices
(
BindDevice
,
&
bind
);
ret
=
pcmcia_bind_device
(
&
bind
);
if
(
ret
!=
CS_SUCCESS
)
{
cs_error
(
NULL
,
BindDevice
,
ret
);
break
;
}
client_reg
.
event_callback_args
.
client_data
=
&
socket_table
[
i
];
ret
=
CardServices
(
RegisterClient
,
&
socket_table
[
i
].
handle
,
ret
=
pcmcia_register_client
(
&
socket_table
[
i
].
handle
,
&
client_reg
);
if
(
ret
!=
CS_SUCCESS
)
{
cs_error
(
NULL
,
RegisterClient
,
ret
);
...
...
@@ -923,7 +919,7 @@ void __exit cleanup_module(void)
if
(
major_dev
!=
-
1
)
unregister_chrdev
(
major_dev
,
"pcmcia"
);
for
(
i
=
0
;
i
<
sockets
;
i
++
)
CardServices
(
DeregisterClient
,
socket_table
[
i
].
handle
);
pcmcia_deregister_client
(
socket_table
[
i
].
handle
);
sockets
=
0
;
kfree
(
socket_table
);
}
...
...
drivers/pcmcia/i82365.c
View file @
0115c1b6
...
...
@@ -2703,7 +2703,7 @@ static int pcic_service(u_int sock, u_int cmd, void *arg)
static
int
__init
init_i82365
(
void
)
{
servinfo_t
serv
;
CardServices
(
GetCardServicesInfo
,
&
serv
);
pcmcia_get_card_services_info
(
&
serv
);
if
(
serv
.
Revision
!=
CS_RELEASE_CODE
)
{
printk
(
KERN_NOTICE
"i82365: Card Services release "
"does not match!
\n
"
);
...
...
drivers/pcmcia/rsrc_mgr.c
View file @
0115c1b6
...
...
@@ -629,7 +629,7 @@ static int adjust_irq(adjust_t *adj)
/*====================================================================*/
int
adjust_resource_info
(
client_handle_t
handle
,
adjust_t
*
adj
)
int
pcmcia_
adjust_resource_info
(
client_handle_t
handle
,
adjust_t
*
adj
)
{
if
(
CHECK_HANDLE
(
handle
))
return
CS_BAD_HANDLE
;
...
...
drivers/pcmcia/tcic.c
View file @
0115c1b6
...
...
@@ -379,7 +379,7 @@ static int __init init_tcic(void)
servinfo_t
serv
;
DEBUG
(
0
,
"%s
\n
"
,
version
);
CardServices
(
GetCardServicesInfo
,
&
serv
);
pcmcia_get_card_services_info
(
&
serv
);
if
(
serv
.
Revision
!=
CS_RELEASE_CODE
)
{
printk
(
KERN_NOTICE
"tcic: Card Services release "
"does not match!
\n
"
);
...
...
include/pcmcia/bulkmem.h
View file @
0115c1b6
...
...
@@ -192,4 +192,16 @@ extern int MTDHelperEntry(int func, void *a1, void *a2);
extern
int
MTDHelperEntry
(
int
func
,
...);
#endif
int
pcmcia_get_first_region
(
client_handle_t
handle
,
region_info_t
*
rgn
);
int
pcmcia_get_next_region
(
client_handle_t
handle
,
region_info_t
*
rgn
);
int
pcmcia_register_mtd
(
client_handle_t
handle
,
mtd_reg_t
*
reg
);
int
pcmcia_register_erase_queue
(
client_handle_t
*
handle
,
eraseq_hdr_t
*
header
);
int
pcmcia_deregister_erase_queue
(
eraseq_handle_t
eraseq
);
int
pcmcia_check_erase_queue
(
eraseq_handle_t
eraseq
);
int
pcmcia_open_memory
(
client_handle_t
*
handle
,
open_mem_t
*
open
);
int
pcmcia_close_memory
(
memory_handle_t
handle
);
int
pcmcia_read_memory
(
memory_handle_t
handle
,
mem_op_t
*
req
,
caddr_t
buf
);
int
pcmcia_write_memory
(
memory_handle_t
handle
,
mem_op_t
*
req
,
caddr_t
buf
);
int
pcmcia_copy_memory
(
memory_handle_t
handle
,
copy_op_t
*
req
);
#endif
/* _LINUX_BULKMEM_H */
include/pcmcia/cistpl.h
View file @
0115c1b6
...
...
@@ -580,4 +580,12 @@ typedef struct cisdump_t {
cisdata_t
Data
[
CISTPL_MAX_CIS_SIZE
];
}
cisdump_t
;
int
pcmcia_get_first_tuple
(
client_handle_t
handle
,
tuple_t
*
tuple
);
int
pcmcia_get_next_tuple
(
client_handle_t
handle
,
tuple_t
*
tuple
);
int
pcmcia_get_tuple_data
(
client_handle_t
handle
,
tuple_t
*
tuple
);
int
pcmcia_parse_tuple
(
client_handle_t
handle
,
tuple_t
*
tuple
,
cisparse_t
*
parse
);
int
pcmcia_validate_cis
(
client_handle_t
handle
,
cisinfo_t
*
info
);
int
pcmcia_replace_cis
(
client_handle_t
handle
,
cisdump_t
*
cis
);
#endif
/* LINUX_CISTPL_H */
include/pcmcia/cs.h
View file @
0115c1b6
...
...
@@ -440,6 +440,42 @@ extern int CardServices(int func, void *a1, void *a2, void *a3);
extern
int
CardServices
(
int
func
,
...);
#endif
int
pcmcia_access_configuration_register
(
client_handle_t
handle
,
conf_reg_t
*
reg
);
int
pcmcia_bind_device
(
bind_req_t
*
req
);
int
pcmcia_bind_mtd
(
mtd_bind_t
*
req
);
int
pcmcia_deregister_client
(
client_handle_t
handle
);
int
pcmcia_get_configuration_info
(
client_handle_t
handle
,
config_info_t
*
config
);
int
pcmcia_get_card_services_info
(
servinfo_t
*
info
);
int
pcmcia_get_first_client
(
client_handle_t
*
handle
,
client_req_t
*
req
);
int
pcmcia_get_next_client
(
client_handle_t
*
handle
,
client_req_t
*
req
);
int
pcmcia_get_window
(
window_handle_t
*
handle
,
int
idx
,
win_req_t
*
req
);
int
pcmcia_get_first_window
(
client_handle_t
*
handle
,
win_req_t
*
req
);
int
pcmcia_get_next_window
(
window_handle_t
*
win
,
win_req_t
*
req
);
int
pcmcia_get_status
(
client_handle_t
handle
,
cs_status_t
*
status
);
int
pcmcia_get_mem_page
(
window_handle_t
win
,
memreq_t
*
req
);
int
pcmcia_map_mem_page
(
window_handle_t
win
,
memreq_t
*
req
);
int
pcmcia_modify_configuration
(
client_handle_t
handle
,
modconf_t
*
mod
);
int
pcmcia_modify_window
(
window_handle_t
win
,
modwin_t
*
req
);
int
pcmcia_register_client
(
client_handle_t
*
handle
,
client_reg_t
*
req
);
int
pcmcia_release_configuration
(
client_handle_t
handle
);
int
pcmcia_release_io
(
client_handle_t
handle
,
io_req_t
*
req
);
int
pcmcia_release_irq
(
client_handle_t
handle
,
irq_req_t
*
req
);
int
pcmcia_release_window
(
window_handle_t
win
);
int
pcmcia_request_configuration
(
client_handle_t
handle
,
config_req_t
*
req
);
int
pcmcia_request_io
(
client_handle_t
handle
,
io_req_t
*
req
);
int
pcmcia_request_irq
(
client_handle_t
handle
,
irq_req_t
*
req
);
int
pcmcia_request_window
(
client_handle_t
*
handle
,
win_req_t
*
req
);
int
pcmcia_reset_card
(
client_handle_t
handle
,
client_req_t
*
req
);
int
pcmcia_suspend_card
(
client_handle_t
handle
,
client_req_t
*
req
);
int
pcmcia_resume_card
(
client_handle_t
handle
,
client_req_t
*
req
);
int
pcmcia_eject_card
(
client_handle_t
handle
,
client_req_t
*
req
);
int
pcmcia_insert_card
(
client_handle_t
handle
,
client_req_t
*
req
);
int
pcmcia_set_event_mask
(
client_handle_t
handle
,
eventmask_t
*
mask
);
int
pcmcia_report_error
(
client_handle_t
handle
,
error_info_t
*
err
);
/* rsrc_mgr.c */
int
pcmcia_adjust_resource_info
(
client_handle_t
handle
,
adjust_t
*
adj
);
#endif
/* __KERNEL__ */
#endif
/* _LINUX_CS_H */
mm/memory.c
View file @
0115c1b6
...
...
@@ -1012,11 +1012,12 @@ static int do_swap_page(struct task_struct * tsk,
swap_free
(
entry
);
if
(
write_access
&&
!
is_page_shared
(
page
))
{
delete_from_swap_cache_nolock
(
page
);
UnlockPage
(
page
);
page
=
replace_with_highmem
(
page
);
pte
=
mk_pte
(
page
,
vma
->
vm_page_prot
);
pte
=
pte_mkwrite
(
pte_mkdirty
(
pte
));
}
UnlockPage
(
page
);
}
else
UnlockPage
(
page
);
set_pte
(
page_table
,
pte
);
/* No need to invalidate - it was non-present before */
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment