mirror of
https://github.com/followmsi/android_kernel_google_msm.git
synced 2024-11-06 23:17:41 +00:00
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/drzeus/mmc
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/drzeus/mmc: net: libertas sdio driver mmc: at91_mci: cleanup: use MCI_ERRORS mmc: possible leak in mmc_read_ext_csd
This commit is contained in:
commit
c2f73fd07d
8 changed files with 1143 additions and 4 deletions
|
@ -213,7 +213,8 @@ static int mmc_read_ext_csd(struct mmc_card *card)
|
|||
printk(KERN_ERR "%s: unrecognised EXT_CSD structure "
|
||||
"version %d\n", mmc_hostname(card->host),
|
||||
ext_csd_struct);
|
||||
return -EINVAL;
|
||||
err = -EINVAL;
|
||||
goto out;
|
||||
}
|
||||
|
||||
if (ext_csd_struct >= 2) {
|
||||
|
|
|
@ -581,9 +581,7 @@ static void at91_mci_completed_command(struct at91mci_host *host)
|
|||
pr_debug("Status = %08X [%08X %08X %08X %08X]\n",
|
||||
status, cmd->resp[0], cmd->resp[1], cmd->resp[2], cmd->resp[3]);
|
||||
|
||||
if (status & (AT91_MCI_RINDE | AT91_MCI_RDIRE | AT91_MCI_RCRCE |
|
||||
AT91_MCI_RENDE | AT91_MCI_RTOE | AT91_MCI_DCRCE |
|
||||
AT91_MCI_DTOE | AT91_MCI_OVRE | AT91_MCI_UNRE)) {
|
||||
if (status & AT91_MCI_ERRORS) {
|
||||
if ((status & AT91_MCI_RCRCE) && !(mmc_resp_type(cmd) & MMC_RSP_CRC)) {
|
||||
cmd->error = 0;
|
||||
}
|
||||
|
|
|
@ -282,6 +282,12 @@ config LIBERTAS_CS
|
|||
---help---
|
||||
A driver for Marvell Libertas 8385 CompactFlash devices.
|
||||
|
||||
config LIBERTAS_SDIO
|
||||
tristate "Marvell Libertas 8385 and 8686 SDIO 802.11b/g cards"
|
||||
depends on LIBERTAS && MMC
|
||||
---help---
|
||||
A driver for Marvell Libertas 8385 and 8686 SDIO devices.
|
||||
|
||||
config LIBERTAS_DEBUG
|
||||
bool "Enable full debugging output in the Libertas module."
|
||||
depends on LIBERTAS
|
||||
|
|
|
@ -7,7 +7,9 @@ libertas-objs := main.o wext.o \
|
|||
|
||||
usb8xxx-objs += if_usb.o
|
||||
libertas_cs-objs += if_cs.o
|
||||
libertas_sdio-objs += if_sdio.o
|
||||
|
||||
obj-$(CONFIG_LIBERTAS) += libertas.o
|
||||
obj-$(CONFIG_LIBERTAS_USB) += usb8xxx.o
|
||||
obj-$(CONFIG_LIBERTAS_CS) += libertas_cs.o
|
||||
obj-$(CONFIG_LIBERTAS_SDIO) += libertas_sdio.o
|
||||
|
|
|
@ -39,6 +39,7 @@
|
|||
#define LBS_DEB_FW 0x00080000
|
||||
#define LBS_DEB_THREAD 0x00100000
|
||||
#define LBS_DEB_HEX 0x00200000
|
||||
#define LBS_DEB_SDIO 0x00400000
|
||||
|
||||
extern unsigned int libertas_debug;
|
||||
|
||||
|
@ -80,6 +81,7 @@ do { if ((libertas_debug & (grp)) == (grp)) \
|
|||
#define lbs_deb_usbd(dev, fmt, args...) LBS_DEB_LL(LBS_DEB_USB, " usbd", "%s:" fmt, (dev)->bus_id, ##args)
|
||||
#define lbs_deb_cs(fmt, args...) LBS_DEB_LL(LBS_DEB_CS, " cs", fmt, ##args)
|
||||
#define lbs_deb_thread(fmt, args...) LBS_DEB_LL(LBS_DEB_THREAD, " thread", fmt, ##args)
|
||||
#define lbs_deb_sdio(fmt, args...) LBS_DEB_LL(LBS_DEB_SDIO, " thread", fmt, ##args)
|
||||
|
||||
#define lbs_pr_info(format, args...) \
|
||||
printk(KERN_INFO DRV_NAME": " format, ## args)
|
||||
|
|
1079
drivers/net/wireless/libertas/if_sdio.c
Normal file
1079
drivers/net/wireless/libertas/if_sdio.c
Normal file
File diff suppressed because it is too large
Load diff
45
drivers/net/wireless/libertas/if_sdio.h
Normal file
45
drivers/net/wireless/libertas/if_sdio.h
Normal file
|
@ -0,0 +1,45 @@
|
|||
/*
|
||||
* linux/drivers/net/wireless/libertas/if_sdio.h
|
||||
*
|
||||
* Copyright 2007 Pierre Ossman
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or (at
|
||||
* your option) any later version.
|
||||
*/
|
||||
|
||||
#ifndef LIBERTAS_IF_SDIO_H
|
||||
#define LIBERTAS_IF_SDIO_H
|
||||
|
||||
#define IF_SDIO_IOPORT 0x00
|
||||
|
||||
#define IF_SDIO_H_INT_MASK 0x04
|
||||
#define IF_SDIO_H_INT_OFLOW 0x08
|
||||
#define IF_SDIO_H_INT_UFLOW 0x04
|
||||
#define IF_SDIO_H_INT_DNLD 0x02
|
||||
#define IF_SDIO_H_INT_UPLD 0x01
|
||||
|
||||
#define IF_SDIO_H_INT_STATUS 0x05
|
||||
#define IF_SDIO_H_INT_RSR 0x06
|
||||
#define IF_SDIO_H_INT_STATUS2 0x07
|
||||
|
||||
#define IF_SDIO_RD_BASE 0x10
|
||||
|
||||
#define IF_SDIO_STATUS 0x20
|
||||
#define IF_SDIO_IO_RDY 0x08
|
||||
#define IF_SDIO_CIS_RDY 0x04
|
||||
#define IF_SDIO_UL_RDY 0x02
|
||||
#define IF_SDIO_DL_RDY 0x01
|
||||
|
||||
#define IF_SDIO_C_INT_MASK 0x24
|
||||
#define IF_SDIO_C_INT_STATUS 0x28
|
||||
#define IF_SDIO_C_INT_RSR 0x2C
|
||||
|
||||
#define IF_SDIO_SCRATCH 0x34
|
||||
#define IF_SDIO_SCRATCH_OLD 0x80fe
|
||||
#define IF_SDIO_FIRMWARE_OK 0xfedc
|
||||
|
||||
#define IF_SDIO_EVENT 0x80fc
|
||||
|
||||
#endif
|
|
@ -19,5 +19,11 @@
|
|||
#define SDIO_CLASS_WLAN 0x07 /* WLAN interface */
|
||||
#define SDIO_CLASS_ATA 0x08 /* Embedded SDIO-ATA std interface */
|
||||
|
||||
/*
|
||||
* Vendors and devices. Sort key: vendor first, device next.
|
||||
*/
|
||||
|
||||
#define SDIO_VENDOR_ID_MARVELL 0x02df
|
||||
#define SDIO_DEVICE_ID_MARVELL_LIBERTAS 0x9103
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue