]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/char/moxa.c
igb: add support for in kernel LRO
[linux-2.6-omap-h63xx.git] / drivers / char / moxa.c
index 6757b1922f4f7b85f9ba3edb759199b56a3f5cf9..d57d3a61919b310f22e972e97cf1c8797334db1d 100644 (file)
@@ -846,7 +846,10 @@ static int moxa_init_board(struct moxa_board_conf *brd, struct device *dev)
 
        ret = request_firmware(&fw, file, dev);
        if (ret) {
-               printk(KERN_ERR "request_firmware failed\n");
+               printk(KERN_ERR "MOXA: request_firmware failed. Make sure "
+                               "you've placed '%s' file into your firmware "
+                               "loader directory (e.g. /lib/firmware)\n",
+                               file);
                goto err_free;
        }
 
@@ -934,7 +937,7 @@ static int __devinit moxa_pci_probe(struct pci_dev *pdev,
                goto err;
        }
 
-       board->basemem = ioremap(pci_resource_start(pdev, 2), 0x4000);
+       board->basemem = ioremap_nocache(pci_resource_start(pdev, 2), 0x4000);
        if (board->basemem == NULL) {
                dev_err(&pdev->dev, "can't remap io space 2\n");
                goto err_reg;
@@ -1039,7 +1042,7 @@ static int __init moxa_init(void)
                        brd->numPorts = type[i] == MOXA_BOARD_C218_ISA ? 8 :
                                        numports[i];
                        brd->busType = MOXA_BUS_TYPE_ISA;
-                       brd->basemem = ioremap(baseaddr[i], 0x4000);
+                       brd->basemem = ioremap_nocache(baseaddr[i], 0x4000);
                        if (!brd->basemem) {
                                printk(KERN_ERR "MOXA: can't remap %lx\n",
                                                baseaddr[i]);
@@ -1277,6 +1280,7 @@ static int moxa_chars_in_buffer(struct tty_struct *tty)
         */
        if (ch == NULL)
                return 0;
+       lock_kernel();
        chars = MoxaPortTxQueue(ch);
        if (chars) {
                /*
@@ -1286,6 +1290,7 @@ static int moxa_chars_in_buffer(struct tty_struct *tty)
                if (!(ch->statusflags & EMPTYWAIT))
                        moxa_setup_empty_event(tty);
        }
+       unlock_kernel();
        return chars;
 }