diff for duplicates of <20070205205636.GA14589@Krystal> diff --git a/a/1.txt b/N1/1.txt index a21fc19..b807971 100644 --- a/a/1.txt +++ b/N1/1.txt @@ -1,13 +1,13 @@ * Benjamin Herrenschmidt (benh@kernel.crashing.org) wrote: > On Mon, 2007-02-05 at 09:29 -0500, Mathieu Desnoyers wrote: > > Missing include in include/asm-powerpc/prom.h -> >=20 +> > > > include/asm-powerpc/prom.h needs to include asm/irq.h because it uses > > irq_of_parse_and_map and NO_IRQ. It applies on 2.6.20. ->=20 +> > I'd rather not do that.... better to move of_irq_to_resource() to -> prom_parse.c=20 ->=20 +> prom_parse.c +> Thanks, this patch should apply on top of the previous patch in this thread. @@ -15,22 +15,20 @@ Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca> --- a/arch/powerpc/kernel/prom_parse.c +++ b/arch/powerpc/kernel/prom_parse.c -@@ -1003,3 +1003,18 @@ int of_irq_map_one(struct device_node *device, int i= -ndex, struct of_irq *out_irq +@@ -1003,3 +1003,18 @@ int of_irq_map_one(struct device_node *device, int index, struct of_irq *out_irq return res; } EXPORT_SYMBOL_GPL(of_irq_map_one); + -+int of_irq_to_resource(struct device_node *dev, int index, struct resource= - *r) ++int of_irq_to_resource(struct device_node *dev, int index, struct resource *r) +{ -+ int irq =3D irq_of_parse_and_map(dev, index); ++ int irq = irq_of_parse_and_map(dev, index); + + /* Only dereference the resource if both the + * resource and the irq are valid. */ -+ if (r && irq !=3D NO_IRQ) { -+ r->start =3D r->end =3D irq; -+ r->flags =3D IORESOURCE_IRQ; ++ if (r && irq != NO_IRQ) { ++ r->start = r->end = irq; ++ r->flags = IORESOURCE_IRQ; + } + + return irq; @@ -38,21 +36,19 @@ ndex, struct of_irq *out_irq +EXPORT_SYMBOL_GPL(of_irq_to_resource); --- a/include/asm-powerpc/prom.h +++ b/include/asm-powerpc/prom.h -@@ -335,20 +335,8 @@ extern int of_irq_map_one(struct device_node *device, = -int index, +@@ -335,20 +335,8 @@ extern int of_irq_map_one(struct device_node *device, int index, struct pci_dev; extern int of_irq_map_pci(struct pci_dev *pdev, struct of_irq *out_irq); -=20 --static inline int of_irq_to_resource(struct device_node *dev, int index, s= -truct resource *r) + +-static inline int of_irq_to_resource(struct device_node *dev, int index, struct resource *r) -{ -- int irq =3D irq_of_parse_and_map(dev, index); +- int irq = irq_of_parse_and_map(dev, index); - - /* Only dereference the resource if both the - * resource and the irq are valid. */ -- if (r && irq !=3D NO_IRQ) { -- r->start =3D r->end =3D irq; -- r->flags =3D IORESOURCE_IRQ; +- if (r && irq != NO_IRQ) { +- r->start = r->end = irq; +- r->flags = IORESOURCE_IRQ; - } - - return irq; @@ -60,10 +56,10 @@ truct resource *r) - +extern int of_irq_to_resource(struct device_node *dev, int index, + struct resource *r); -=20 + #endif /* __KERNEL__ */ #endif /* _POWERPC_PROM_H */ ---=20 +-- Mathieu Desnoyers -Computer Engineering Graduate Student, =C9cole Polytechnique de Montr=E9al +Computer Engineering Graduate Student, École Polytechnique de Montréal OpenPGP key fingerprint: 8CD5 52C3 8E3C 4140 715F BA06 3F25 A8FE 3BAE 9A68 diff --git a/a/content_digest b/N1/content_digest index 101f5e2..704c9f5 100644 --- a/a/content_digest +++ b/N1/content_digest @@ -4,22 +4,22 @@ "Subject\0Re: [PATCH] Missing include in include/asm-powerpc/prom.h\0" "Date\0Mon, 5 Feb 2007 15:56:36 -0500\0" "To\0Benjamin Herrenschmidt <benh@kernel.crashing.org>\0" - "Cc\0Andrew Morton <akpm@osdl.org>" - linuxppc-dev@ozlabs.org + "Cc\0linux-kernel@vger.kernel.org" + Andrew Morton <akpm@osdl.org> paulus@samba.org - " linux-kernel@vger.kernel.org\0" + " linuxppc-dev@ozlabs.org\0" "\00:1\0" "b\0" "* Benjamin Herrenschmidt (benh@kernel.crashing.org) wrote:\n" "> On Mon, 2007-02-05 at 09:29 -0500, Mathieu Desnoyers wrote:\n" "> > Missing include in include/asm-powerpc/prom.h\n" - "> >=20\n" + "> > \n" "> > include/asm-powerpc/prom.h needs to include asm/irq.h because it uses\n" "> > irq_of_parse_and_map and NO_IRQ. It applies on 2.6.20.\n" - ">=20\n" + "> \n" "> I'd rather not do that.... better to move of_irq_to_resource() to\n" - "> prom_parse.c=20\n" - ">=20\n" + "> prom_parse.c \n" + "> \n" "\n" "Thanks, this patch should apply on top of the previous patch in this thread.\n" "\n" @@ -27,22 +27,20 @@ "\n" "--- a/arch/powerpc/kernel/prom_parse.c\n" "+++ b/arch/powerpc/kernel/prom_parse.c\n" - "@@ -1003,3 +1003,18 @@ int of_irq_map_one(struct device_node *device, int i=\n" - "ndex, struct of_irq *out_irq\n" + "@@ -1003,3 +1003,18 @@ int of_irq_map_one(struct device_node *device, int index, struct of_irq *out_irq\n" " \treturn res;\n" " }\n" " EXPORT_SYMBOL_GPL(of_irq_map_one);\n" "+\n" - "+int of_irq_to_resource(struct device_node *dev, int index, struct resource=\n" - " *r)\n" + "+int of_irq_to_resource(struct device_node *dev, int index, struct resource *r)\n" "+{\n" - "+\tint irq =3D irq_of_parse_and_map(dev, index);\n" + "+\tint irq = irq_of_parse_and_map(dev, index);\n" "+\n" "+\t/* Only dereference the resource if both the\n" "+\t * resource and the irq are valid. */\n" - "+\tif (r && irq !=3D NO_IRQ) {\n" - "+\t\tr->start =3D r->end =3D irq;\n" - "+\t\tr->flags =3D IORESOURCE_IRQ;\n" + "+\tif (r && irq != NO_IRQ) {\n" + "+\t\tr->start = r->end = irq;\n" + "+\t\tr->flags = IORESOURCE_IRQ;\n" "+\t}\n" "+\n" "+\treturn irq;\n" @@ -50,21 +48,19 @@ "+EXPORT_SYMBOL_GPL(of_irq_to_resource);\n" "--- a/include/asm-powerpc/prom.h\n" "+++ b/include/asm-powerpc/prom.h\n" - "@@ -335,20 +335,8 @@ extern int of_irq_map_one(struct device_node *device, =\n" - "int index,\n" + "@@ -335,20 +335,8 @@ extern int of_irq_map_one(struct device_node *device, int index,\n" " struct pci_dev;\n" " extern int of_irq_map_pci(struct pci_dev *pdev, struct of_irq *out_irq);\n" - "=20\n" - "-static inline int of_irq_to_resource(struct device_node *dev, int index, s=\n" - "truct resource *r)\n" + " \n" + "-static inline int of_irq_to_resource(struct device_node *dev, int index, struct resource *r)\n" "-{\n" - "-\tint irq =3D irq_of_parse_and_map(dev, index);\n" + "-\tint irq = irq_of_parse_and_map(dev, index);\n" "-\n" "-\t/* Only dereference the resource if both the\n" "-\t * resource and the irq are valid. */\n" - "-\tif (r && irq !=3D NO_IRQ) {\n" - "-\t\tr->start =3D r->end =3D irq;\n" - "-\t\tr->flags =3D IORESOURCE_IRQ;\n" + "-\tif (r && irq != NO_IRQ) {\n" + "-\t\tr->start = r->end = irq;\n" + "-\t\tr->flags = IORESOURCE_IRQ;\n" "-\t}\n" "-\n" "-\treturn irq;\n" @@ -72,12 +68,12 @@ "-\n" "+extern int of_irq_to_resource(struct device_node *dev, int index,\n" "+\t\t\tstruct resource *r);\n" - "=20\n" + " \n" " #endif /* __KERNEL__ */\n" " #endif /* _POWERPC_PROM_H */\n" - "--=20\n" + "-- \n" "Mathieu Desnoyers\n" - "Computer Engineering Graduate Student, =C9cole Polytechnique de Montr=E9al\n" + "Computer Engineering Graduate Student, \303\211cole Polytechnique de Montr\303\251al\n" OpenPGP key fingerprint: 8CD5 52C3 8E3C 4140 715F BA06 3F25 A8FE 3BAE 9A68 -3968831b11d9b8f606b7b24de5e8c187758cdea3736797ee58bab525a856ef48 +e236df6c4e74c291f40e8256beb80bf1f99a1a7c826ee6acde52605b171de04e
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.