[PATCH] pci_dma_mapping_error in 2.6.5

Olaf Hering olh at suse.de
Sat Mar 27 03:59:55 EST 2004


I'm not sure if this patch is correct,
at least the compiler is now happy.


diff -purN /tmp/linux-2.6.4/drivers/net/iseries_veth.c ./drivers/net/iseries_veth.c
--- /tmp/linux-2.6.4/drivers/net/iseries_veth.c 2004-03-26 16:28:22.000000000 +0000
+++ ./drivers/net/iseries_veth.c        2004-03-26 16:46:26.000000000 +0000
@@ -455,7 +455,7 @@ static int veth_transmit_to_one(struct s

        /* Is it really necessary to check the length and address
         * fields of the first entry here? */
-       if (!pci_dma_error(dma_address)) {
+       if (!pci_dma_mapping_error(dma_address)) {
                msg->skb = skb;
                msg->data.addr[0] = dma_address;
                msg->data.len[0] = dma_length;
diff -purN /tmp/linux-2.6.4/drivers/scsi/ibmvscsi/ibmvscsis.c ./drivers/scsi/ibmvscsi/ibmvscsis.c
--- /tmp/linux-2.6.4/drivers/scsi/ibmvscsi/ibmvscsis.c  2004-03-26 16:28:22.000000000 +0000
+++ ./drivers/scsi/ibmvscsi/ibmvscsis.c 2004-03-26 16:46:22.000000000 +0000
@@ -1863,7 +1863,7 @@ static int initialize_crq_queue(struct c
                                          queue->size * sizeof(*queue->msgs),
                                          PCI_DMA_BIDIRECTIONAL);

-       if (pci_dma_error(queue->msg_token))
+       if (pci_dma_mapping_error(queue->msg_token))
                goto map_failed;

        rc = plpar_hcall_norets(H_REG_CRQ, adapter->dma_dev->unit_address, queue->msg_token, PAGE_SIZE);
diff -purN /tmp/linux-2.6.4/drivers/scsi/ibmvscsi/rpa_vscsi.c ./drivers/scsi/ibmvscsi/rpa_vscsi.c
--- /tmp/linux-2.6.4/drivers/scsi/ibmvscsi/rpa_vscsi.c  2004-03-26 16:28:22.000000000 +0000
+++ ./drivers/scsi/ibmvscsi/rpa_vscsi.c 2004-03-26 16:47:44.000000000 +0000
@@ -169,7 +169,7 @@ int ibmvscsi_init_crq_queue(struct crq_q
                                          queue->size * sizeof(*queue->msgs),
                                          PCI_DMA_BIDIRECTIONAL);

-       if (pci_dma_error(queue->msg_token))
+       if (pci_dma_mapping_error(queue->msg_token))
                goto map_failed;

        rc = plpar_hcall_norets(H_REG_CRQ,

--
USB is for mice, FireWire is for men!

sUse lINUX ag, nÜRNBERG

** Sent via the linuxppc64-dev mail list. See http://lists.linuxppc.org/





More information about the Linuxppc64-dev mailing list