From 5ae8cb9525f0481025b9bc156c7a181aff7ded47 Mon Sep 17 00:00:00 2001 From: Greg Kroah-Hartman Date: Tue, 11 May 2010 15:51:53 -0700 Subject: [PATCH] Staging: wlags49: build fixes Now that the code actually gets selected in the kernel config properly, all of the build errors start showing up. This patch papers over a few of them to get the code to build, I have no idea if it actually works now or not... Cc: Henk de Groot Signed-off-by: Greg Kroah-Hartman --- drivers/staging/wlags49_h2/dhf.c | 10 +++++----- drivers/staging/wlags49_h2/wl_cs.c | 14 +++++++------- 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/drivers/staging/wlags49_h2/dhf.c b/drivers/staging/wlags49_h2/dhf.c index d5fb1a97e855..80a4707885d8 100644 --- a/drivers/staging/wlags49_h2/dhf.c +++ b/drivers/staging/wlags49_h2/dhf.c @@ -286,14 +286,14 @@ int i; fw->signature[i+1] != (/* HCF_BIG_ENDIAN ? 'B' : */ 'L')) rc = DHF_ERR_INCOMP_FW; else { /* Little Endian Binary format */ - fw->codep = (CFG_PROG_STRCT FAR*)((PSEUDO_CHARP)fw->codep + (hcf_32)fw); - fw->identity = (CFG_IDENTITY_STRCT FAR*)((PSEUDO_CHARP)fw->identity + (hcf_32)fw); - fw->compat = (CFG_RANGE20_STRCT FAR*)((PSEUDO_CHARP)fw->compat + (hcf_32)fw); + fw->codep = (CFG_PROG_STRCT FAR*)((char *)fw->codep + (hcf_32)fw); + fw->identity = (CFG_IDENTITY_STRCT FAR*)((char *)fw->identity + (hcf_32)fw); + fw->compat = (CFG_RANGE20_STRCT FAR*)((char *)fw->compat + (hcf_32)fw); for (i = 0; fw->p[i]; i++) - fw->p[i] = ((PSEUDO_CHARP)fw->p[i] + (hcf_32)fw); + fw->p[i] = ((char *)fw->p[i] + (hcf_32)fw); p = fw->codep; while (p->len) { - p->host_addr = (PSEUDO_CHARP)p->host_addr + (hcf_32)fw; + p->host_addr = (char *)p->host_addr + (hcf_32)fw; p++; } } diff --git a/drivers/staging/wlags49_h2/wl_cs.c b/drivers/staging/wlags49_h2/wl_cs.c index 9da42e66085e..7c33eade6b8a 100644 --- a/drivers/staging/wlags49_h2/wl_cs.c +++ b/drivers/staging/wlags49_h2/wl_cs.c @@ -157,14 +157,14 @@ static int wl_adapter_attach(struct pcmcia_device *link) link->io.Attributes1 = IO_DATA_PATH_WIDTH_16; link->io.IOAddrLines = 6; link->irq.Attributes = IRQ_TYPE_DYNAMIC_SHARING | IRQ_HANDLE_PRESENT; - link->irq.IRQInfo1 = IRQ_INFO2_VALID | IRQ_LEVEL_ID; +// link->irq.IRQInfo1 = IRQ_INFO2_VALID | IRQ_LEVEL_ID; link->irq.Handler = &wl_isr; link->conf.Attributes = CONF_ENABLE_IRQ; link->conf.IntType = INT_MEMORY_AND_IO; link->conf.ConfigIndex = 5; link->conf.Present = PRESENT_OPTION; - link->priv = link->irq.Instance = dev; + link->priv = dev; lp = wl_priv(dev); lp->link = link; @@ -317,15 +317,15 @@ void wl_adapter_insert( struct pcmcia_device *link ) /* Do we need to allocate an interrupt? */ link->conf.Attributes |= CONF_ENABLE_IRQ; - CS_CHECK(RequestIO, pcmcia_request_io(link, &link->io)); - CS_CHECK(RequestIRQ, pcmcia_request_irq(link, &link->irq)); - CS_CHECK(RequestConfiguration, pcmcia_request_configuration(link, &link->conf)); +// CS_CHECK(RequestIO, pcmcia_request_io(link, &link->io)); +// CS_CHECK(RequestIRQ, pcmcia_request_irq(link, &link->irq)); +// CS_CHECK(RequestConfiguration, pcmcia_request_configuration(link, &link->conf)); dev->irq = link->irq.AssignedIRQ; dev->base_addr = link->io.BasePort1; - SET_NETDEV_DEV(dev, &handle_to_dev(link)); + SET_NETDEV_DEV(dev, &link->dev); if (register_netdev(dev) != 0) { printk("%s: register_netdev() failed\n", MODULE_NAME); goto failed; @@ -345,7 +345,7 @@ void wl_adapter_insert( struct pcmcia_device *link ) cs_failed: - cs_error( link, last_fn, last_ret ); +// cs_error( link, last_fn, last_ret ); failed: -- 2.30.2