Commit ff274f25 authored by Dominik Brodowski's avatar Dominik Brodowski Committed by Linus Torvalds

[PATCH] pcmcia: remove obsolete code

Remove the code marked as obsolete -- nobody complained.
Signed-off-by: default avatarDominik Broodwski <linux@brodo.de>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent 18c71d48
......@@ -39,18 +39,6 @@ config PCMCIA_DEBUG
In all the above examples, N is the debugging verbosity
level.
config PCMCIA_OBSOLETE
bool "Enable obsolete PCCARD code"
depends on PCCARD != n
help
Say Y here to enable some code found in the PCCARD subsystem
which has no in-kernel usage, but might be needed for certain
external PCMCIA drivers. If you do need to say Y here so that
one such driver compiles and/or works correctly, please report
this to linux-pcmcia <at> lists.infradead.org
If unsure, say N
config PCMCIA
tristate "16-bit PCMCIA support"
depends on PCCARD
......
......@@ -152,49 +152,3 @@ int pccard_get_next_region(struct pcmcia_socket *s, region_info_t *rgn)
return pccard_match_region(rgn->next, rgn);
} /* get_next_region */
#ifdef CONFIG_PCMCIA_OBSOLETE
static int match_region(client_handle_t handle, memory_handle_t list,
region_info_t *match)
{
while (list != NULL) {
if (!(handle->Attributes & INFO_MTD_CLIENT) ||
(strcmp(handle->dev_info, list->dev_info) == 0)) {
*match = list->info;
return CS_SUCCESS;
}
list = list->info.next;
}
return CS_NO_MORE_ITEMS;
} /* match_region */
int pcmcia_get_first_region(client_handle_t handle, region_info_t *rgn)
{
struct pcmcia_socket *s = SOCKET(handle);
if (CHECK_HANDLE(handle))
return CS_BAD_HANDLE;
if ((handle->Attributes & INFO_MASTER_CLIENT) &&
(!(s->state & SOCKET_REGION_INFO))) {
setup_regions(s, handle->Function, 0, &s->c_region);
setup_regions(s, handle->Function, 1, &s->a_region);
s->state |= SOCKET_REGION_INFO;
}
if (rgn->Attributes & REGION_TYPE_AM)
return match_region(handle, s->a_region, rgn);
else
return match_region(handle, s->c_region, rgn);
} /* get_first_region */
EXPORT_SYMBOL(pcmcia_get_first_region);
int pcmcia_get_next_region(client_handle_t handle, region_info_t *rgn)
{
if (CHECK_HANDLE(handle))
return CS_BAD_HANDLE;
return match_region(handle, rgn->next, rgn);
} /* get_next_region */
EXPORT_SYMBOL(pcmcia_get_next_region);
#endif
......@@ -1147,37 +1147,6 @@ int pcmcia_modify_configuration(client_handle_t handle,
return CS_SUCCESS;
} /* modify_configuration */
#ifdef CONFIG_PCMCIA_OBSOLETE
/*======================================================================
Modify the attributes of a window returned by RequestWindow.
======================================================================*/
int pcmcia_modify_window(window_handle_t win, modwin_t *req)
{
if ((win == NULL) || (win->magic != WINDOW_MAGIC))
return CS_BAD_HANDLE;
win->ctl.flags &= ~(MAP_ATTRIB|MAP_ACTIVE);
if (req->Attributes & WIN_MEMORY_TYPE)
win->ctl.flags |= MAP_ATTRIB;
if (req->Attributes & WIN_ENABLE)
win->ctl.flags |= MAP_ACTIVE;
if (req->Attributes & WIN_DATA_WIDTH_16)
win->ctl.flags |= MAP_16BIT;
if (req->Attributes & WIN_USE_WAIT)
win->ctl.flags |= MAP_USE_WAIT;
win->ctl.speed = req->AccessSpeed;
win->sock->ops->set_mem_map(win->sock, &win->ctl);
return CS_SUCCESS;
} /* modify_window */
EXPORT_SYMBOL(pcmcia_modify_window);
#endif /* CONFIG_PCMCIA_OBSOLETE */
/* register pcmcia_callback */
int pccard_register_pcmcia(struct pcmcia_socket *s, struct pcmcia_callback *c)
{
......@@ -1863,35 +1832,6 @@ int pcmcia_insert_card(struct pcmcia_socket *skt)
return ret;
} /* insert_card */
/*======================================================================
Maybe this should send a CS_EVENT_CARD_INSERTION event if we
haven't sent one to this client yet?
======================================================================*/
#ifdef CONFIG_PCMCIA_OBSOLETE
int pcmcia_set_event_mask(client_handle_t handle, eventmask_t *mask)
{
u_int events, bit;
if (CHECK_HANDLE(handle))
return CS_BAD_HANDLE;
if (handle->Attributes & CONF_EVENT_MASK_VALID)
return CS_BAD_SOCKET;
handle->EventMask = mask->EventMask;
events = handle->PendingEvents & handle->EventMask;
handle->PendingEvents -= events;
while (events != 0) {
bit = ((events ^ (events-1)) + 1) >> 1;
EVENT(handle, bit, CS_EVENT_PRI_LOW);
events -= bit;
}
return CS_SUCCESS;
} /* set_event_mask */
EXPORT_SYMBOL(pcmcia_set_event_mask);
#endif /* CONFIG_PCMCIA_OBSOLETE */
/*======================================================================
OS-specific module glue goes here
......
......@@ -123,23 +123,3 @@ int pcmcia_access_configuration_register(client_handle_t handle,
}
EXPORT_SYMBOL(pcmcia_access_configuration_register);
#ifdef CONFIG_PCMCIA_OBSOLETE
int pcmcia_get_first_window(window_handle_t *win, win_req_t *req)
{
if ((win == NULL) || ((*win)->magic != WINDOW_MAGIC))
return CS_BAD_HANDLE;
return pcmcia_get_window(((client_handle_t)*win)->Socket, win, 0, req);
}
EXPORT_SYMBOL(pcmcia_get_first_window);
int pcmcia_get_next_window(window_handle_t *win, win_req_t *req)
{
if ((win == NULL) || ((*win)->magic != WINDOW_MAGIC))
return CS_BAD_HANDLE;
return pcmcia_get_window((*win)->sock, win, (*win)->index+1, req);
}
EXPORT_SYMBOL(pcmcia_get_next_window);
#endif
......@@ -419,13 +419,6 @@ int pcmcia_eject_card(struct pcmcia_socket *skt);
int pcmcia_insert_card(struct pcmcia_socket *skt);
int pcmcia_report_error(client_handle_t handle, error_info_t *err);
#ifdef CONFIG_PCMCIA_OBSOLETE
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_modify_window(window_handle_t win, modwin_t *req);
int pcmcia_set_event_mask(client_handle_t handle, eventmask_t *mask);
#endif
struct pcmcia_socket * pcmcia_get_socket(struct pcmcia_socket *skt);
void pcmcia_put_socket(struct pcmcia_socket *skt);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment