Re: [PATCH] [2.4] forcedeth network driver

From: Francois Romieu (romieu_at_fr.zoreil.com)
Date: 01/24/04

  • Next message: Michael Buesch: "[2.6.2-rc1] BTTV, RTC and I2C warning messages"
    Date:	Sat, 24 Jan 2004 19:59:51 +0100
    To: Carl-Daniel Hailfinger <c-d.hailfinger.kernel.2004@gmx.net>
    
    

    Carl-Daniel Hailfinger <c-d.hailfinger.kernel.2004@gmx.net> :
    [current version of forcedeth]

    +static int __devinit probe_nic(struct pci_dev *pci_dev, const struct pci_device_id *id)
    +{
    [...]
    + dev = alloc_etherdev(sizeof(struct fe_priv));
    + np = get_nvpriv(dev);
    + err = -ENOMEM;
    + if (!dev)
    + goto out;

    -> get_npriv() can still dereference a NULL pointer.

    [...]
    + err = pci_request_regions(pci_dev, dev->name);
    + if (err < 0)
    + goto out_disable;
    [...]
    + if (i == DEVICE_COUNT_RESOURCE) {
    + printk(KERN_INFO "forcedeth: Couldn't find register window for device %s.\n",
    + pci_name(pci_dev));
    + goto out_relreg;
    [...]
    + if (!dev->base_addr)
    + goto out_disable;
                         ^^^^^^^^^^^
    -> shouldn't it be out_relreg ?

    --
    Ueimor
    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at  http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at  http://www.tux.org/lkml/
    

  • Next message: Michael Buesch: "[2.6.2-rc1] BTTV, RTC and I2C warning messages"

    Relevant Pages

    • [PATCH] Fix pci_bus_find_capability()
      ... pulls the guts of pci_bus_find_capabilityand pci_find_capability ... pci_find_capability(struct pci_dev *dev, int cap) ... send the line "unsubscribe linux-kernel" in ...
      (Linux-Kernel)
    • [PATCH] kill 8139too kernel thread (sorta)
      ... static void mdio_write (struct net_device *dev, int phy_id, int location, ... static struct ethtool_ops rtl8139_ethtool_ops; ... send the line "unsubscribe linux-kernel" in ...
      (Linux-Kernel)
    • Re: State of devfs in 2.6?
      ... > dev directory, ... Module autoloading is useful, ... send the line "unsubscribe linux-kernel" in ...
      (Linux-Kernel)
    • Re: "deadlock" between smc91x driver and link_watch
      ... whether smc_phy_configure is pending or not instead of dev_hold/put. ... -static void smc_detect_phy(struct net_device *dev) ... +static void smc_phy_detect ... To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/ ...
      (Linux-Kernel)
    • pm_message_t to struct conversion [was Re: 2.6.12-rc1-mm1: Kernel BUG at pci:389]
      ... static ssize_t state_show(struct device * dev, ... target sleep state for the whole system ... +typedef struct pm_message { ... To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/ ...
      (Linux-Kernel)