[patch 04/16] powerpc: remove dead code in iommu.h
Benjamin Herrenschmidt
benh at kernel.crashing.org
Fri Nov 3 09:21:53 EST 2006
On Thu, 2006-11-02 at 13:55 +0100, s.hauer at pengutronix.de wrote:
> plain text document attachment
> (powerpc-include-asm-powerpc-iommu_h-remove-dead-code.diff)
> iommu_setup_pSeries() and iommu_setup_dart() are declared extern but are
> not implemented, so remove them. iommu_free_table() is pSeries specific,
> so #ifdef it with CONFIG_PPC_PSERIES and not CONFIG_PPC_MULTIPLATFORM
>
> Signed-off-by: Sascha Hauer <s.hauer at pengutronix.de>
There is no need to #ifdef an extern declaration. Just remove the
ifdef's and the two obsolete prototypes alltogether
Cheers,
Ben.
> Index: linux-2.6/include/asm-powerpc/iommu.h
> ===================================================================
> --- linux-2.6.orig/include/asm-powerpc/iommu.h
> +++ linux-2.6/include/asm-powerpc/iommu.h
> @@ -70,16 +70,12 @@ struct iommu_table {
> struct scatterlist;
> struct device_node;
>
> -#ifdef CONFIG_PPC_MULTIPLATFORM
> -
> -/* Walks all buses and creates iommu tables */
> -extern void iommu_setup_pSeries(void);
> -extern void iommu_setup_dart(void);
> +#ifdef CONFIG_PPC_PSERIES
>
> /* Frees table for an individual device node */
> extern void iommu_free_table(struct device_node *dn);
>
> -#endif /* CONFIG_PPC_MULTIPLATFORM */
> +#endif /* CONFIG_PPC_PSERIES */
>
> /* Initializes an iommu_table based in values set in the passed-in
> * structure
>
> --
> Dipl.-Ing. Sascha Hauer | http://www.pengutronix.de
> Pengutronix - Linux Solutions for Science and Industry
> Handelsregister: Amtsgericht Hildesheim, HRA 2686
> Hannoversche Str. 2, 31134 Hildesheim, Germany
> Phone: +49-5121-206917-0 | Fax: +49-5121-206917-9
> _______________________________________________
> Linuxppc-dev mailing list
> Linuxppc-dev at ozlabs.org
> https://ozlabs.org/mailman/listinfo/linuxppc-dev
More information about the Linuxppc-dev
mailing list