mirror of
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-09-18 22:14:16 +00:00
Merge branch 'pcmcia-next' of git://git.kernel.org/pub/scm/linux/kernel/git/brodo/linux
Pull pcmcia updates from Dominik Brodowski: "A few odd cleanups and fixes, including a Kconfig fix to add a required dependency on MIPS" * 'pcmcia-next' of git://git.kernel.org/pub/scm/linux/kernel/git/brodo/linux: pcmcia: Use platform_get_irq() to get the interrupt pcmcia: db1xxx_ss: restrict to MIPS_DB1XXX boards drivers/pcmcia: Fix typo in comment
This commit is contained in:
commit
2380dd691e
3 changed files with 7 additions and 6 deletions
|
@ -151,7 +151,7 @@ config TCIC
|
||||||
|
|
||||||
config PCMCIA_ALCHEMY_DEVBOARD
|
config PCMCIA_ALCHEMY_DEVBOARD
|
||||||
tristate "Alchemy Db/Pb1xxx PCMCIA socket services"
|
tristate "Alchemy Db/Pb1xxx PCMCIA socket services"
|
||||||
depends on MIPS_ALCHEMY && PCMCIA
|
depends on MIPS_DB1XXX && PCMCIA
|
||||||
help
|
help
|
||||||
Enable this driver of you want PCMCIA support on your Alchemy
|
Enable this driver of you want PCMCIA support on your Alchemy
|
||||||
Db1000, Db/Pb1100, Db/Pb1500, Db/Pb1550, Db/Pb1200, DB1300
|
Db1000, Db/Pb1100, Db/Pb1500, Db/Pb1550, Db/Pb1200, DB1300
|
||||||
|
|
|
@ -327,10 +327,11 @@ static int bcm63xx_drv_pcmcia_probe(struct platform_device *pdev)
|
||||||
{
|
{
|
||||||
struct bcm63xx_pcmcia_socket *skt;
|
struct bcm63xx_pcmcia_socket *skt;
|
||||||
struct pcmcia_socket *sock;
|
struct pcmcia_socket *sock;
|
||||||
struct resource *res, *irq_res;
|
struct resource *res;
|
||||||
unsigned int regmem_size = 0, iomem_size = 0;
|
unsigned int regmem_size = 0, iomem_size = 0;
|
||||||
u32 val;
|
u32 val;
|
||||||
int ret;
|
int ret;
|
||||||
|
int irq;
|
||||||
|
|
||||||
skt = kzalloc(sizeof(*skt), GFP_KERNEL);
|
skt = kzalloc(sizeof(*skt), GFP_KERNEL);
|
||||||
if (!skt)
|
if (!skt)
|
||||||
|
@ -342,9 +343,9 @@ static int bcm63xx_drv_pcmcia_probe(struct platform_device *pdev)
|
||||||
/* make sure we have all resources we need */
|
/* make sure we have all resources we need */
|
||||||
skt->common_res = platform_get_resource(pdev, IORESOURCE_MEM, 1);
|
skt->common_res = platform_get_resource(pdev, IORESOURCE_MEM, 1);
|
||||||
skt->attr_res = platform_get_resource(pdev, IORESOURCE_MEM, 2);
|
skt->attr_res = platform_get_resource(pdev, IORESOURCE_MEM, 2);
|
||||||
irq_res = platform_get_resource(pdev, IORESOURCE_IRQ, 0);
|
irq = platform_get_irq(pdev, 0);
|
||||||
skt->pd = pdev->dev.platform_data;
|
skt->pd = pdev->dev.platform_data;
|
||||||
if (!skt->common_res || !skt->attr_res || !irq_res || !skt->pd) {
|
if (!skt->common_res || !skt->attr_res || (irq < 0) || !skt->pd) {
|
||||||
ret = -EINVAL;
|
ret = -EINVAL;
|
||||||
goto err;
|
goto err;
|
||||||
}
|
}
|
||||||
|
@ -380,7 +381,7 @@ static int bcm63xx_drv_pcmcia_probe(struct platform_device *pdev)
|
||||||
sock->dev.parent = &pdev->dev;
|
sock->dev.parent = &pdev->dev;
|
||||||
sock->features = SS_CAP_STATIC_MAP | SS_CAP_PCCARD;
|
sock->features = SS_CAP_STATIC_MAP | SS_CAP_PCCARD;
|
||||||
sock->io_offset = (unsigned long)skt->io_base;
|
sock->io_offset = (unsigned long)skt->io_base;
|
||||||
sock->pci_irq = irq_res->start;
|
sock->pci_irq = irq;
|
||||||
|
|
||||||
#ifdef CONFIG_CARDBUS
|
#ifdef CONFIG_CARDBUS
|
||||||
sock->cb_dev = bcm63xx_cb_dev;
|
sock->cb_dev = bcm63xx_cb_dev;
|
||||||
|
|
|
@ -394,7 +394,7 @@ static int do_validate_mem(struct pcmcia_socket *s,
|
||||||
* do_mem_probe() checks a memory region for use by the PCMCIA subsystem.
|
* do_mem_probe() checks a memory region for use by the PCMCIA subsystem.
|
||||||
* To do so, the area is split up into sensible parts, and then passed
|
* To do so, the area is split up into sensible parts, and then passed
|
||||||
* into the @validate() function. Only if @validate() and @fallback() fail,
|
* into the @validate() function. Only if @validate() and @fallback() fail,
|
||||||
* the area is marked as unavaibale for use by the PCMCIA subsystem. The
|
* the area is marked as unavailable for use by the PCMCIA subsystem. The
|
||||||
* function returns the size of the usable memory area.
|
* function returns the size of the usable memory area.
|
||||||
*/
|
*/
|
||||||
static int do_mem_probe(struct pcmcia_socket *s, u_long base, u_long num,
|
static int do_mem_probe(struct pcmcia_socket *s, u_long base, u_long num,
|
||||||
|
|
Loading…
Add table
Reference in a new issue