[patchset "b23" updated] new sysfs-based resource interface for non-static sockets

Dominik Brodowski linux at dominikbrodowski.de
Mon Nov 22 10:47:02 EST 2004


An updated version of the "b23" pcmcia patchset is available at
http://www.brodo.de/patches/2004-11-22/pcmcia-b23-rsrc-sysfs.tar.bz2

Changes to the previous version include:
- moved 01-alloc-db-per-socket, 02-remove-typedef and 03-lock-in-release to b22
- rediff

A "bigdiff" is available at
http://www.brodo.de/patches/2004-11-22/pcmcia-b23-complete

and individual patches as follows:

http://www.brodo.de/patches/2004-11-22/pcmcia-b23-rsrc-sysfs/01-sysfs-resource-output

Add sysfs output to the non-static resource database. It'll reside in 
/sys/class/pcmcia_socket/pcmcia_socket%n/device_possible_resources_{io_mem}
and be of the format

"0x08%lx - 0x%08%lx\n"


http://www.brodo.de/patches/2004-11-22/pcmcia-b23-rsrc-sysfs/02-sysfs-resource-input

Add a sysfs input method for the non-static socket resource database. It
works by writing 
"+ 0x%[l]x - 0x%[l]x"
for adding resources, and by
"- 0x%[l]x - 0x%[l]x"
for removing resources to
/sys/class/pcmcia_socket/pcmcia_socket%n/device_possible_resources_{io_mem}


http://www.brodo.de/patches/2004-11-22/pcmcia-b23-rsrc-sysfs/03-sysfs-resource-done

PCMCIA device registration should only happen if we're quite confident
there are resources available to at least map the CIS space -- else we can't
determine manfid/cardid, whether it is a multifunction card, etc. So,
add a flag to struct pcmcia_socket which denotes that -- and also whether
resources were added the "old" adjust_resource_info way. On static sockets,
it is activated upon registration, on non-static sockets, it is set upon an
echo'ing of anything into 
/sys/class/pcmcia_socket/pcmcia_socket%n/device_possible_resources_setup_done



More information about the linux-pcmcia mailing list