Commit a5276db2 authored by Matthew Wilcox's avatar Matthew Wilcox Committed by Christoph Hellwig

[PATCH] Two small fixes for sym53c8xx_2

Both of these patches are originally by Grant Grundler.  They've been
tested in the PA-RISC tree for a few months, and I'm forwarding them along.

First patch:

pci_set_dma_mask returns 0 if the card can perform DMA as specified,
so the sense of the test is wrong.
parent 5a2c251b
......@@ -1876,7 +1876,7 @@ static int sym_setup_bus_dma_mask(hcb_p np)
sym_name(np));
}
else {
if (!pci_set_dma_mask(np->s.device, 0xffffffffUL))
if (pci_set_dma_mask(np->s.device, 0xffffffffUL))
goto out_err32;
}
}
......
......@@ -143,12 +143,15 @@ static void ___sym_mfree(m_pool_p mp, void *ptr, int size)
a = (m_addr_t) ptr;
while (1) {
#ifdef SYM_MEM_FREE_UNUSED
if (s == SYM_MEM_CLUSTER_SIZE) {
#ifdef SYM_MEM_FREE_UNUSED
M_FREE_MEM_CLUSTER(a);
#else
((m_link_p) a)->next = h[i].next;
h[i].next = (m_link_p) a;
#endif
break;
}
#endif
b = a ^ s;
q = &h[i];
while (q->next && q->next != (m_link_p) b) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment