Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

alpha: compile fixes

- jensen build: fix conflicting declarations for pci_alloc_consistent()
and undefined virt_to_phys();

- SMP: arch/alpha/kernel/smp.c:124: warning: passing argument 2
of '__cpu_test_and_set' discards qualifiers from pointer target type
Interestingly, this only happens with gcc-4.2; gcc <= 4.1 and gcc-4.3
are OK. Fixed with extra assignment.

Signed-off-by: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
Cc: Richard Henderson <rth@twiddle.net>
Cc: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

authored by

Ivan Kokshaysky and committed by
Linus Torvalds
ee0c468b e5d9a90c

+6 -2
+2
arch/alpha/include/asm/dma-mapping.h
··· 29 29 30 30 #else /* no PCI - no IOMMU. */ 31 31 32 + #include <asm/io.h> /* for virt_to_phys() */ 33 + 32 34 struct scatterlist; 33 35 void *dma_alloc_coherent(struct device *dev, size_t size, 34 36 dma_addr_t *dma_handle, gfp_t gfp);
+2 -1
arch/alpha/kernel/pci-noop.c
··· 109 109 /* Stubs for the routines in pci_iommu.c: */ 110 110 111 111 void * 112 - pci_alloc_consistent(struct pci_dev *pdev, size_t size, dma_addr_t *dma_addrp) 112 + __pci_alloc_consistent(struct pci_dev *pdev, size_t size, 113 + dma_addr_t *dma_addrp, gfp_t gfp) 113 114 { 114 115 return NULL; 115 116 }
+2 -1
arch/alpha/kernel/smp.c
··· 120 120 smp_callin(void) 121 121 { 122 122 int cpuid = hard_smp_processor_id(); 123 + cpumask_t mask = cpu_online_map; 123 124 124 - if (cpu_test_and_set(cpuid, cpu_online_map)) { 125 + if (cpu_test_and_set(cpuid, mask)) { 125 126 printk("??, cpu 0x%x already present??\n", cpuid); 126 127 BUG(); 127 128 }