From mboxrd@z Thu Jan 1 00:00:00 1970 From: Matthew Garrett Date: Tue, 31 Jan 2006 18:26:39 +0000 Subject: Autoloading of mmc_block for SD/MMC interfaces Message-Id: <20060131182638.GA13475@srcf.ucam.org> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: linux-hotplug@vger.kernel.org Hi, Currently, mmc_block isn't autoloaded when an MMC or SD card is inserted. On card insertion, /sys/bus/mmc/devices/mmc0:0001 (or similar) is created. In this is a file called csd, which is a dump of 128 bits of card specific data. According to drivers/mmc/mmc.c, the 12 bits starting at bit 84 define the commands that the card will respond to. include/linux/mmc/protocol.h specifies these - if bit 2 is set (BLOCK_READ), then mmc_block should be loaded. Sample dump: tyrosine% cat /sys/bus/mmc/devices/mmc0:0001/csd 8c7f002a1f5983d3f6da8fff9e600000 ^^^ 12 bits - 0x95f 100101011111 ^ CCC_BLOCK_READ -- Matthew Garrett | mjg59@srcf.ucam.org ------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnk&kid3432&bid#0486&dat1642 _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net Linux-hotplug-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel