{
int devid,devrev,oldid,x_devid,x_devrev,x_oldid;
+ if (!request_region(io, 3, __FUNCTION__))
+ return;
+
/* First probe without key */
outb(0x20,io);
x_devid=inb(io+1);
outb(0xaa,io); /* Magic Seal */
if ((x_devid == devid) && (x_devrev == devrev) && (x_oldid == oldid))
- return; /* protection against false positives */
+ goto out; /* protection against false positives */
decode_winbond(io,key,devid,devrev,oldid);
+out:
+ release_region(io, 3);
}
static void __devinit winbond_check2(int io,int key)
{
int devid,devrev,oldid,x_devid,x_devrev,x_oldid;
+ if (!request_region(io, 3, __FUNCTION__))
+ return;
+
/* First probe without the key */
outb(0x20,io+2);
x_devid=inb(io+2);
outb(0xaa,io); /* Magic Seal */
if ((x_devid == devid) && (x_devrev == devrev) && (x_oldid == oldid))
- return; /* protection against false positives */
+ goto out; /* protection against false positives */
- decode_winbond(io,key,devid,devrev,oldid);
+ decode_winbond(io,key,devid,devrev,oldid);
+out:
+ release_region(io, 3);
}
static void __devinit smsc_check(int io, int key)
{
int id,rev,oldid,oldrev,x_id,x_rev,x_oldid,x_oldrev;
+ if (!request_region(io, 3, __FUNCTION__))
+ return;
+
/* First probe without the key */
outb(0x0d,io);
x_oldid=inb(io+1);
if ((x_id == id) && (x_oldrev == oldrev) &&
(x_oldid == oldid) && (x_rev == rev))
- return; /* protection against false positives */
+ goto out; /* protection against false positives */
decode_smsc(io,key,oldid,oldrev);
+out:
+ release_region(io, 3);
}
priv->ctr_writable = ~0x10;
priv->ecr = 0;
priv->fifo_depth = 0;
- priv->dma_buf = 0;
+ priv->dma_buf = NULL;
priv->dma_handle = 0;
priv->dev = dev;
INIT_LIST_HEAD(&priv->list);
oxsemi_840,
aks_0100,
mobility_pp,
+ netmos_9705,
+ netmos_9805,
+ netmos_9815,
+ netmos_9855,
+ netmos_9735,
+ netmos_9835,
+ netmos_9755,
+ netmos_9715
};
* and 840 locks up if you write 1 to bit 2! */
/* oxsemi_954 */ { 1, { { 0, -1 }, } },
/* oxsemi_840 */ { 1, { { 0, -1 }, } },
- /* aks_0100 */ { 1, { { 0, 1 }, } },
+ /* aks_0100 */ { 1, { { 0, -1 }, } },
/* mobility_pp */ { 1, { { 0, 1 }, } },
+ /* netmos_9705 */ { 1, { { 0, -1 }, } }, /* untested */
+ /* netmos_9805 */ { 1, { { 0, -1 }, } }, /* untested */
+ /* netmos_9815 */ { 2, { { 0, -1 }, { 2, -1 }, } }, /* untested */
+ /* netmos_9855 */ { 2, { { 0, -1 }, { 2, -1 }, } }, /* untested */
+ /* netmos_9735 */ { 1, { { 2, 3 }, } }, /* untested */
+ /* netmos_9835 */ { 1, { { 2, 3 }, } }, /* untested */
+ /* netmos_9755 */ { 2, { { 0, 1 }, { 2, 3 },} }, /* untested */
+ /* netmos_9715 */ { 2, { { 0, 1 }, { 2, 3 },} }, /* untested */
};
static struct pci_device_id parport_pc_pci_tbl[] = {
PCI_ANY_ID, PCI_ANY_ID, 0, 0, oxsemi_840 },
{ PCI_VENDOR_ID_AKS, PCI_DEVICE_ID_AKS_ALADDINCARD,
PCI_ANY_ID, PCI_ANY_ID, 0, 0, aks_0100 },
+ /* NetMos communication controllers */
+ { PCI_VENDOR_ID_NETMOS, PCI_DEVICE_ID_NETMOS_9705,
+ PCI_ANY_ID, PCI_ANY_ID, 0, 0, netmos_9705 },
+ { PCI_VENDOR_ID_NETMOS, PCI_DEVICE_ID_NETMOS_9805,
+ PCI_ANY_ID, PCI_ANY_ID, 0, 0, netmos_9805 },
+ { PCI_VENDOR_ID_NETMOS, PCI_DEVICE_ID_NETMOS_9815,
+ PCI_ANY_ID, PCI_ANY_ID, 0, 0, netmos_9815 },
+ { PCI_VENDOR_ID_NETMOS, PCI_DEVICE_ID_NETMOS_9855,
+ PCI_ANY_ID, PCI_ANY_ID, 0, 0, netmos_9855 },
+ { PCI_VENDOR_ID_NETMOS, PCI_DEVICE_ID_NETMOS_9735,
+ PCI_ANY_ID, PCI_ANY_ID, 0, 0, netmos_9735 },
+ { PCI_VENDOR_ID_NETMOS, PCI_DEVICE_ID_NETMOS_9835,
+ PCI_ANY_ID, PCI_ANY_ID, 0, 0, netmos_9835 },
+ { PCI_VENDOR_ID_NETMOS, PCI_DEVICE_ID_NETMOS_9755,
+ PCI_ANY_ID, PCI_ANY_ID, 0, 0, netmos_9755 },
+ { PCI_VENDOR_ID_NETMOS, PCI_DEVICE_ID_NETMOS_9715,
+ PCI_ANY_ID, PCI_ANY_ID, 0, 0, netmos_9715 },
{ 0, } /* terminate list */
};
MODULE_DEVICE_TABLE(pci,parport_pc_pci_tbl);