* [KJ] use kzalloc instead of kcalloc(1,
@ 2005-11-27 20:36 Marion Jaillet
2005-11-27 21:23 ` Nishanth Aravamudan
` (6 more replies)
0 siblings, 7 replies; 8+ messages in thread
From: Marion Jaillet @ 2005-11-27 20:36 UTC (permalink / raw)
To: kernel-janitors
[-- Attachment #1: Type: text/plain, Size: 114 bytes --]
Patch against linux-2.6.14.2
Signed-off-by : Christophe Jaillet
Desc : use kzalloc instead of kcalloc(1,...)
CJ
[-- Attachment #2: patch1.c --]
[-- Type: application/octet-stream, Size: 503 bytes --]
--- arch/ia64/sn/kernel/io_init.c.bak 2005-11-11 06:33:12.000000000 +0100
+++ arch/ia64/sn/kernel/io_init.c 2005-11-27 21:17:18.000000000 +0100
@@ -351,7 +351,7 @@ void sn_pci_controller_fixup(int segment
return; /*bus # does not exist */
prom_bussoft_ptr = __va(prom_bussoft_ptr);
- controller = kcalloc(1,sizeof(struct pci_controller), GFP_KERNEL);
+ controller = kzalloc(sizeof(struct pci_controller), GFP_KERNEL);
controller->segment = segment;
if (!controller)
BUG();
[-- Attachment #3: Type: text/plain, Size: 168 bytes --]
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [KJ] use kzalloc instead of kcalloc(1,
2005-11-27 20:36 [KJ] use kzalloc instead of kcalloc(1, Marion Jaillet
@ 2005-11-27 21:23 ` Nishanth Aravamudan
2005-11-28 1:38 ` Nishanth Aravamudan
` (5 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: Nishanth Aravamudan @ 2005-11-27 21:23 UTC (permalink / raw)
To: kernel-janitors
[-- Attachment #1: Type: text/plain, Size: 584 bytes --]
On 27.11.2005 [21:36:51 +0100], Marion Jaillet wrote:
> Patch against linux-2.6.14.2
Please patch against current mainline (e.g. 2.6.15-rc2)
> Signed-off-by : Christophe Jaillet
Signed-off-by lines have a standard form (from SubmittingPatches).
"Signed-off-by: Random J Developer <random@developer.example.org>"
> Desc : use kzalloc instead of kcalloc(1,...)
Patch should be inlined if possible. Also, it's not a .c file (it's a
patch, not code).
Finally, patch needs to be -p1 applicable. diff -urpN from the parent
directory of the source should be sufficient.
Thanks,
Nish
[-- Attachment #2: Type: text/plain, Size: 168 bytes --]
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [KJ] use kzalloc instead of kcalloc(1,
2005-11-27 20:36 [KJ] use kzalloc instead of kcalloc(1, Marion Jaillet
2005-11-27 21:23 ` Nishanth Aravamudan
@ 2005-11-28 1:38 ` Nishanth Aravamudan
2005-11-28 1:41 ` Alexey Dobriyan
` (4 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: Nishanth Aravamudan @ 2005-11-28 1:38 UTC (permalink / raw)
To: kernel-janitors
[-- Attachment #1: Type: text/plain, Size: 589 bytes --]
On 28.11.2005 [04:41:54 +0300], Alexey Dobriyan wrote:
> On Sun, Nov 27, 2005 at 01:23:10PM -0800, Nishanth Aravamudan wrote:
> > On 27.11.2005 [21:36:51 +0100], Marion Jaillet wrote:
> > > Patch against linux-2.6.14.2
> >
> > Please patch against current mainline (e.g. 2.6.15-rc2)
>
> True, but this particular occurence is already replaced. Also, kmalloc()
> error checking in this file is funny.
Yeah, I kinda hoped this was the case (without looking). Point being, we
can avoid unnecessary patches on the ML if all patches are against
current mainline when submitted.
Thanks,
Nish
[-- Attachment #2: Type: text/plain, Size: 168 bytes --]
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [KJ] use kzalloc instead of kcalloc(1,
2005-11-27 20:36 [KJ] use kzalloc instead of kcalloc(1, Marion Jaillet
2005-11-27 21:23 ` Nishanth Aravamudan
2005-11-28 1:38 ` Nishanth Aravamudan
@ 2005-11-28 1:41 ` Alexey Dobriyan
2005-11-28 21:40 ` Christophe Jaillet
` (3 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: Alexey Dobriyan @ 2005-11-28 1:41 UTC (permalink / raw)
To: kernel-janitors
[-- Attachment #1: Type: text/plain, Size: 331 bytes --]
On Sun, Nov 27, 2005 at 01:23:10PM -0800, Nishanth Aravamudan wrote:
> On 27.11.2005 [21:36:51 +0100], Marion Jaillet wrote:
> > Patch against linux-2.6.14.2
>
> Please patch against current mainline (e.g. 2.6.15-rc2)
True, but this particular occurence is already replaced. Also, kmalloc()
error checking in this file is funny.
[-- Attachment #2: Type: text/plain, Size: 168 bytes --]
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors
^ permalink raw reply [flat|nested] 8+ messages in thread
* [KJ] use kzalloc instead of kcalloc(1,
2005-11-27 20:36 [KJ] use kzalloc instead of kcalloc(1, Marion Jaillet
` (2 preceding siblings ...)
2005-11-28 1:41 ` Alexey Dobriyan
@ 2005-11-28 21:40 ` Christophe Jaillet
2005-11-28 21:59 ` Nish Aravamudan
` (2 subsequent siblings)
6 siblings, 0 replies; 8+ messages in thread
From: Christophe Jaillet @ 2005-11-28 21:40 UTC (permalink / raw)
To: kernel-janitors
[-- Attachment #1.1: Type: text/plain, Size: 1265 bytes --]
from: Christophe Jaillet christophe.jaillet@wanadoo.fr
use kzalloc instead of kcalloc(1,...) in /kernel/kprobes.c and /include/linux/gameport.h
Signed-off-by : Christophe Jaillet christophe.jaillet@wanadoo.fr
---
Patch applicable to linux-2.6.15-rc2
I hope that for this third try :
the form is OK
the patch is usefull
CJ
--- linux-2.6.14.2/kernel/kprobes.c.old 2005-11-11 06:33:12.000000000 +0100
+++ linux-2.6.14.2/kernel/kprobes.c 2005-11-28 22:20:58.000000000 +0100
@@ -420,3 +420,3 @@ static inline void add_aggr_kprobe(struc
* the intricacies
- * TODO: Move kcalloc outside the spinlock
+ * TODO: Move kzalloc outside the spinlock
*/
@@ -432,3 +432,3 @@ static int __kprobes register_aggr_kprob
} else {
- ap = kcalloc(1, sizeof(struct kprobe), GFP_ATOMIC);
+ ap = kzalloc(sizeof(struct kprobe), GFP_ATOMIC);
if (!ap)
--- linux-2.6.14.2/include/linux/gameport.h.old 2005-11-11 06:33:12.000000000 +0100
+++ linux-2.6.14.2/include/linux/gameport.h 2005-11-28 22:19:48.000000000 +0100
@@ -104,3 +104,3 @@ static inline struct gameport *gameport_
{
- struct gameport *gameport = kcalloc(1, sizeof(struct gameport), GFP_KERNEL);
+ struct gameport *gameport = kzalloc(sizeof(struct gameport), GFP_KERNEL);
[-- Attachment #1.2: Type: text/html, Size: 2046 bytes --]
[-- Attachment #2: Type: text/plain, Size: 168 bytes --]
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [KJ] use kzalloc instead of kcalloc(1,
2005-11-27 20:36 [KJ] use kzalloc instead of kcalloc(1, Marion Jaillet
` (3 preceding siblings ...)
2005-11-28 21:40 ` Christophe Jaillet
@ 2005-11-28 21:59 ` Nish Aravamudan
2005-11-28 22:12 ` Jesper Juhl
2005-11-29 21:42 ` Alexey Dobriyan
6 siblings, 0 replies; 8+ messages in thread
From: Nish Aravamudan @ 2005-11-28 21:59 UTC (permalink / raw)
To: kernel-janitors
On 11/28/05, Christophe Jaillet <christophe.jaillet@wanadoo.fr> wrote:
>
>
> from: Christophe Jaillet christophe.jaillet@wanadoo.fr
>
> use kzalloc instead of kcalloc(1,...) in /kernel/kprobes.c and
> /include/linux/gameport.h
> Signed-off-by : Christophe Jaillet christophe.jaillet@wanadoo.fr
Brackets around the e-mail address please (in both From & Signed-off-by).
Otherwise ok, I think.
Thanks,
Nish
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [KJ] use kzalloc instead of kcalloc(1,
2005-11-27 20:36 [KJ] use kzalloc instead of kcalloc(1, Marion Jaillet
` (4 preceding siblings ...)
2005-11-28 21:59 ` Nish Aravamudan
@ 2005-11-28 22:12 ` Jesper Juhl
2005-11-29 21:42 ` Alexey Dobriyan
6 siblings, 0 replies; 8+ messages in thread
From: Jesper Juhl @ 2005-11-28 22:12 UTC (permalink / raw)
To: kernel-janitors
On Monday 28 November 2005 22:40, Christophe Jaillet wrote:
> from: Christophe Jaillet christophe.jaillet@wanadoo.fr
>
> use kzalloc instead of kcalloc(1,...) in /kernel/kprobes.c and /include/linux/gameport.h
> Signed-off-by : Christophe Jaillet christophe.jaillet@wanadoo.fr
> ---
> Patch applicable to linux-2.6.15-rc2
>
> I hope that for this third try :
> the form is OK
> the patch is usefull
Patch looks ok to me, but doesn't seem to want to apply:
juhl@dragon:~/kernel/linux-2.6.15-rc2$ patch -p1 < ../Christophe.patch
patching file kernel/kprobes.c
Hunk #1 FAILED at 420.
Hunk #2 FAILED at 432.
2 out of 2 hunks FAILED -- saving rejects to file kernel/kprobes.c.rej
patching file include/linux/gameport.h
Hunk #1 FAILED at 104.
1 out of 1 hunk FAILED -- saving rejects to file include/linux/gameport.h.rej
Could be due to the email encoding or you generated the patch against a
different kernel version? I didn't investigate...
Ohh and another thing, if ever you plan to send patches to LKML, then this
> Content-Type: text/html;
> charset="iso-8859-1"
is a very bad idea as it'll cause your mail to never reach the mailing list.
Just use plain text.
--
Jesper Juhl <jesper.juhl@gmail.com>
Don't top-post http://www.catb.org/~esr/jargon/html/T/top-post.html
Plain text mails only, please http://www.expita.com/nomime.html
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [KJ] use kzalloc instead of kcalloc(1,
2005-11-27 20:36 [KJ] use kzalloc instead of kcalloc(1, Marion Jaillet
` (5 preceding siblings ...)
2005-11-28 22:12 ` Jesper Juhl
@ 2005-11-29 21:42 ` Alexey Dobriyan
6 siblings, 0 replies; 8+ messages in thread
From: Alexey Dobriyan @ 2005-11-29 21:42 UTC (permalink / raw)
To: kernel-janitors
[-- Attachment #1: Type: text/plain, Size: 1093 bytes --]
On Tue, Nov 29, 2005 at 07:02:13AM +0100, Daniel Marjam?ki wrote:
> I believe you are patching against the wrong version, my friend.
>
> I applied the changes manually and then made a new patch:
:-/ Every time I view it in mutt, everything is OK. Every time I save
email, I get space-space at the beggining of context lines, which, of course,
confuses patch(1).
> --- a/kernel/kprobes.c
> +++ b/kernel/kprobes.c
> @@ -408,7 +408,7 @@ static inline void add_aggr_kprobe(struc
> /*
> * This is the second or subsequent kprobe at the address - handle
> * the intricacies
> - * TODO: Move kcalloc outside the spin_lock
> + * TODO: Move kzalloc outside the spin_lock
> */
> static int __kprobes register_aggr_kprobe(struct kprobe *old_p,
> struct kprobe *p)
> @@ -420,7 +420,7 @@ static int __kprobes register_aggr_kprob
> copy_kprobe(old_p, p);
> ret = add_new_kprobe(old_p, p);
> } else {
> - ap = kcalloc(1, sizeof(struct kprobe), GFP_ATOMIC);
> + ap = kzalloc(sizeof(struct kprobe), GFP_ATOMIC);
> if (!ap)
> return -ENOMEM;
> add_aggr_kprobe(ap, old_p);
[-- Attachment #2: Type: text/plain, Size: 168 bytes --]
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2005-11-29 21:42 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-11-27 20:36 [KJ] use kzalloc instead of kcalloc(1, Marion Jaillet
2005-11-27 21:23 ` Nishanth Aravamudan
2005-11-28 1:38 ` Nishanth Aravamudan
2005-11-28 1:41 ` Alexey Dobriyan
2005-11-28 21:40 ` Christophe Jaillet
2005-11-28 21:59 ` Nish Aravamudan
2005-11-28 22:12 ` Jesper Juhl
2005-11-29 21:42 ` Alexey Dobriyan
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.