Fix a compile warning in pci_32.c
Subsystems (2)
PATCH 1/1 Fix a compile warning in pci_32.c
__must_check, so do so.
Signed-off-by Segher Boessenkool <[email protected]>
--- arch/powerpc/kernel/pci_32.c | 5 ++++- 1 files changed, 4 insertions(+), 1 deletions(-)
arch/powerpc/kernel/pci_32.c +4 -1
@@ -581,8 +581,11 @@ pcibios_assign_resources(void)if ((r->flags &IORESOURCE_UNSET ) && r->end && (!ppc_md.pcibios_enable_device_hook || !ppc_md.pcibios_enable_device_hook (dev,1 ))) { +int rc; + r->flags &= ~IORESOURCE_UNSET ; -pci_assign_resource (dev, idx); + rc =pci_assign_resource (dev, idx); +BUG_ON (rc); } }
Signature · 1 line
1.5.2.1.144.gabc40-dirty
PATCH 1/1 Fix a compile warning in powermac/feature.c
...by using the pci_get API instead of the deprecated old stuff.
Signed-off-by Segher Boessenkool <[email protected]>
--- arch/powerpc/platforms/powermac/feature.c | 6 ++++-- 1 files changed, 4 insertions(+), 2 deletions(-)
arch/powerpc/platforms/powermac/feature.c +4 -2
@@ -826,13 +826,15 @@ core99_ata100_enable(struct device_node *node, long value)if (value) {if (pci_device_from_OF_node (node, &pbus, &pid) ==0 ) - pdev =pci_find_slot (pbus, pid); + pdev =pci_get_bus_and_slot (pbus, pid);if (pdev ==NULL )return 0 ; rc =pci_enable_device (pdev); +if (rc ==0 ) +pci_set_master (pdev); +pci_dev_put (pdev);if (rc)return rc; -pci_set_master (pdev); }return 0 ; }
Signature · 1 line
1.5.2.1.144.gabc40-dirty
PATCH 1/1 Replace a few #defines with empty inline functions
...so that GCC doesn't complain about unused variables in the callers of these.
Signed-off-by Segher Boessenkool <[email protected]>
--- include/asm-powerpc/dma-mapping.h | 24 ++++++++++++++++++------ 1 files changed, 18 insertions(+), 6 deletions(-)
include/asm-powerpc/dma-mapping.h +18 -6
@@ -249,8 +249,12 @@ dma_map_single(struct device *dev, void *ptr, size_t size,return virt_to_bus (ptr); } -/* We do nothing. */ -#define dma_unmap_single (dev, addr, size, dir) ((void)0) +static inline void dma_unmap_single (struct device *dev,dma_addr_t dma_addr, +size_t size, +enum dma_data_direction direction) +{ +/* We do nothing. */ +} static inline dma_addr_t dma_map_page(struct device *dev, struct page *page,
@@ -264,8 +268,12 @@ dma_map_page(struct device *dev, struct page *page,return page_to_bus (page) + offset; } -/* We do nothing. */ -#define dma_unmap_page (dev, handle, size, dir) ((void)0) +static inline void dma_unmap_page (struct device *dev,dma_addr_t dma_address, +size_t size, +enum dma_data_direction direction) +{ +/* We do nothing. */ +} static inline int dma_map_sg(struct device *dev, struct scatterlist *sg, int nents,
@@ -284,8 +292,12 @@ dma_map_sg(struct device *dev, struct scatterlist *sg, int nents, return nents; } -/* We don't do anything here. */ -#define dma_unmap_sg (dev, sg, nents, dir) ((void)0) +static inline void dma_unmap_sg (struct device *dev,struct scatterlist *sg, +int nhwentries, +enum dma_data_direction direction) +{ +/* We don't do anything here. */ +}#endif /* CONFIG_PPC64 */
Signature · 1 line
1.5.2.1.144.gabc40-dirty
PATCH 1/1 ide/ppc/pmac: Remove a few unused variables
Signed-off-by Segher Boessenkool <[email protected]>
--- drivers/ide/ppc/pmac.c | 2 -- 1 files changed, 0 insertions(+), 2 deletions(-)
drivers/ide/ppc/pmac.c +0 -2
@@ -1810,9 +1810,7 @@ pmac_ide_dma_check(ide_drive_t *drive) {struct hd_driveid *id = drive->id;ide_hwif_t *hwif =HWIF (drive); -pmac_ide_hwif_t * pmif = (pmac_ide_hwif_t *)hwif->hwif_data;int enable =1 ; -int map; drive->using_dma =0 ;if (drive->media == ide_floppy)
Signature · 1 line
1.5.2.1.144.gabc40-dirty