]> git.hungrycats.org Git - linux/commit
[PCMCIA] 15-get_firstnext_region.diff
authorDominik Brodowski <linux@de.rmk.(none)>
Mon, 18 Oct 2004 23:18:15 +0000 (00:18 +0100)
committerRussell King <rmk@flint.arm.linux.org.uk>
Mon, 18 Oct 2004 23:18:15 +0000 (00:18 +0100)
commit0848d6f4c3afbe943a83863f16813b19cd4ded41
treeb751d6fef5bc4b6122a9ced5bdf40d897b5701e2
parent92ceceb494b291dfd09ba92bdba4f1236cd749fc
[PCMCIA] 15-get_firstnext_region.diff

pcmcia_get_{first,next}_region are tricky: they're used
only by ds.c, but to keep backwards compatibility proper
wrappers are needed (for the moment). However, match_region()
doesn't work without knowing about ds.c's handle, it seems...
but wait:

    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;
    }

as ds.c's handle doesn't have INFO_MTD_CLIENT, the if always
succeeds -- allowing is to simplify it for ds.c. However, this
means we need special functions for ds.c. It's not too large,
fortunately.
drivers/pcmcia/bulkmem.c
drivers/pcmcia/cs_internal.h
drivers/pcmcia/ds.c