Hi, Your series seems to have some coding style problems. See output below for more information:
Type: series Message-id: [email protected] Subject: [Qemu-devel] [PATCH] This patch looks for uses of malloc and convert them to g_malloc === TEST SCRIPT BEGIN === #!/bin/bash BASE=base n=1 total=$(git log --oneline $BASE.. | wc -l) failed=0 # Useful git options git config --local diff.renamelimit 0 git config --local diff.renames True commits="$(git log --format=%H --reverse $BASE..)" for c in $commits; do echo "Checking PATCH $n/$total: $(git show --no-patch --format=%s $c)..." if ! git show $c --format=email | ./scripts/checkpatch.pl --mailback -; then failed=1 echo fi n=$((n+1)) done exit $failed === TEST SCRIPT END === Updating 3c8cf5a9c21ff8782164d1def7f44bd888713384 From https://github.com/patchew-project/qemu - [tag update] patchew/[email protected] -> patchew/[email protected] Switched to a new branch 'test' 21dd718 This patch looks for uses of malloc and convert them to g_malloc === OUTPUT BEGIN === Checking PATCH 1/1: This patch looks for uses of malloc and convert them to g_malloc... Argument "m" isn't numeric in numeric eq (==) at ./scripts/checkpatch.pl line 2459. Argument "m" isn't numeric in numeric eq (==) at ./scripts/checkpatch.pl line 2459. Use of uninitialized value $1 in concatenation (.) or string at ./scripts/checkpatch.pl line 2460. Argument "m" isn't numeric in numeric eq (==) at ./scripts/checkpatch.pl line 2459. Use of uninitialized value $1 in concatenation (.) or string at ./scripts/checkpatch.pl line 2460. Argument "m" isn't numeric in numeric eq (==) at ./scripts/checkpatch.pl line 2459. Use of uninitialized value $1 in concatenation (.) or string at ./scripts/checkpatch.pl line 2460. Argument "m" isn't numeric in numeric eq (==) at ./scripts/checkpatch.pl line 2459. Use of uninitialized value $1 in concatenation (.) or string at ./scripts/checkpatch.pl line 2460. Argument "m" isn't numeric in numeric eq (==) at ./scripts/checkpatch.pl line 2459. Use of uninitialized value $1 in concatenation (.) or string at ./scripts/checkpatch.pl line 2460. Argument "m" isn't numeric in numeric eq (==) at ./scripts/checkpatch.pl line 2459. Use of uninitialized value $1 in concatenation (.) or string at ./scripts/checkpatch.pl line 2460. Argument "m" isn't numeric in numeric eq (==) at ./scripts/checkpatch.pl line 2459. Use of uninitialized value $1 in concatenation (.) or string at ./scripts/checkpatch.pl line 2460. ERROR: spaces required around that '*' (ctx:VxV) #57: FILE: bsd-user/elfload.c:1194: + elf_phdata = (struct elf_phdr *)g_malloc(elf_ex.e_phentsize*elf_ex.e_phnum); ^ ERROR: unnecessary cast may hide bugs, use g_new instead #57: FILE: bsd-user/elfload.c:1194: + elf_phdata = (struct elf_phdr *)g_malloc(elf_ex.e_phentsize*elf_ex.e_phnum); ERROR: unnecessary cast may hide bugs, use g_new instead #66: FILE: bsd-user/elfload.c:1247: + elf_interpreter = (char *)g_malloc(elf_ppnt->p_filesz); ERROR: space prohibited between function name and open parenthesis '(' #92: FILE: disas/m68k.c:1889: + opc_pointer[0] = g_malloc (sizeof (struct m68k_opcode *) ERROR: space prohibited between function name and open parenthesis '(' #92: FILE: disas/m68k.c:1889: + opc_pointer[0] = g_malloc (sizeof (struct m68k_opcode *) ERROR: space prohibited between function name and open parenthesis '(' #105: FILE: disas/sparc.c:2626: + hash_buf = g_malloc (sizeof (* hash_buf) * num_opcodes); ERROR: space prohibited between function name and open parenthesis '(' #105: FILE: disas/sparc.c:2626: + hash_buf = g_malloc (sizeof (* hash_buf) * num_opcodes); ERROR: space prohibited after that '*' (ctx:BxW) #105: FILE: disas/sparc.c:2626: + hash_buf = g_malloc (sizeof (* hash_buf) * num_opcodes); ^ ERROR: space prohibited between function name and open parenthesis '(' #114: FILE: disas/sparc.c:2688: + g_malloc (sparc_num_opcodes * sizeof (sparc_opcode *)); ERROR: space prohibited between function name and open parenthesis '(' #114: FILE: disas/sparc.c:2688: + g_malloc (sparc_num_opcodes * sizeof (sparc_opcode *)); ERROR: code indent should never use tabs #127: FILE: hw/audio/fmopl.c:621: +^Iif( (TL_TABLE = g_malloc(TL_MAX*2*sizeof(INT32))) == NULL)$ ERROR: spaces required around that '*' (ctx:VxV) #127: FILE: hw/audio/fmopl.c:621: + if( (TL_TABLE = g_malloc(TL_MAX*2*sizeof(INT32))) == NULL) ^ ERROR: spaces required around that '*' (ctx:VxV) #127: FILE: hw/audio/fmopl.c:621: + if( (TL_TABLE = g_malloc(TL_MAX*2*sizeof(INT32))) == NULL) ^ ERROR: space prohibited after that open parenthesis '(' #127: FILE: hw/audio/fmopl.c:621: + if( (TL_TABLE = g_malloc(TL_MAX*2*sizeof(INT32))) == NULL) ERROR: space required before the open parenthesis '(' #127: FILE: hw/audio/fmopl.c:621: + if( (TL_TABLE = g_malloc(TL_MAX*2*sizeof(INT32))) == NULL) ERROR: do not use assignment in if condition #127: FILE: hw/audio/fmopl.c:621: + if( (TL_TABLE = g_malloc(TL_MAX*2*sizeof(INT32))) == NULL) ERROR: braces {} are necessary for all arms of this statement #127: FILE: hw/audio/fmopl.c:621: + if( (TL_TABLE = g_malloc(TL_MAX*2*sizeof(INT32))) == NULL) [...] ERROR: code indent should never use tabs #130: FILE: hw/audio/fmopl.c:623: +^Iif( (SIN_TABLE = g_malloc(SIN_ENT*4 *sizeof(INT32 *))) == NULL)$ ERROR: spaces required around that '*' (ctx:VxV) #130: FILE: hw/audio/fmopl.c:623: + if( (SIN_TABLE = g_malloc(SIN_ENT*4 *sizeof(INT32 *))) == NULL) ^ ERROR: spaces required around that '*' (ctx:WxV) #130: FILE: hw/audio/fmopl.c:623: + if( (SIN_TABLE = g_malloc(SIN_ENT*4 *sizeof(INT32 *))) == NULL) ^ ERROR: space prohibited after that open parenthesis '(' #130: FILE: hw/audio/fmopl.c:623: + if( (SIN_TABLE = g_malloc(SIN_ENT*4 *sizeof(INT32 *))) == NULL) ERROR: space required before the open parenthesis '(' #130: FILE: hw/audio/fmopl.c:623: + if( (SIN_TABLE = g_malloc(SIN_ENT*4 *sizeof(INT32 *))) == NULL) ERROR: do not use assignment in if condition #130: FILE: hw/audio/fmopl.c:623: + if( (SIN_TABLE = g_malloc(SIN_ENT*4 *sizeof(INT32 *))) == NULL) ERROR: code indent should never use tabs #136: FILE: hw/audio/fmopl.c:628: +^Iif( (AMS_TABLE = g_malloc(AMS_ENT*2 *sizeof(INT32))) == NULL)$ ERROR: spaces required around that '*' (ctx:VxV) #136: FILE: hw/audio/fmopl.c:628: + if( (AMS_TABLE = g_malloc(AMS_ENT*2 *sizeof(INT32))) == NULL) ^ ERROR: spaces required around that '*' (ctx:WxV) #136: FILE: hw/audio/fmopl.c:628: + if( (AMS_TABLE = g_malloc(AMS_ENT*2 *sizeof(INT32))) == NULL) ^ ERROR: space prohibited after that open parenthesis '(' #136: FILE: hw/audio/fmopl.c:628: + if( (AMS_TABLE = g_malloc(AMS_ENT*2 *sizeof(INT32))) == NULL) ERROR: space required before the open parenthesis '(' #136: FILE: hw/audio/fmopl.c:628: + if( (AMS_TABLE = g_malloc(AMS_ENT*2 *sizeof(INT32))) == NULL) ERROR: do not use assignment in if condition #136: FILE: hw/audio/fmopl.c:628: + if( (AMS_TABLE = g_malloc(AMS_ENT*2 *sizeof(INT32))) == NULL) ERROR: code indent should never use tabs #143: FILE: hw/audio/fmopl.c:634: +^Iif( (VIB_TABLE = g_malloc(VIB_ENT*2 *sizeof(INT32))) == NULL)$ ERROR: spaces required around that '*' (ctx:VxV) #143: FILE: hw/audio/fmopl.c:634: + if( (VIB_TABLE = g_malloc(VIB_ENT*2 *sizeof(INT32))) == NULL) ^ ERROR: spaces required around that '*' (ctx:WxV) #143: FILE: hw/audio/fmopl.c:634: + if( (VIB_TABLE = g_malloc(VIB_ENT*2 *sizeof(INT32))) == NULL) ^ ERROR: space prohibited after that open parenthesis '(' #143: FILE: hw/audio/fmopl.c:634: + if( (VIB_TABLE = g_malloc(VIB_ENT*2 *sizeof(INT32))) == NULL) ERROR: space required before the open parenthesis '(' #143: FILE: hw/audio/fmopl.c:634: + if( (VIB_TABLE = g_malloc(VIB_ENT*2 *sizeof(INT32))) == NULL) ERROR: do not use assignment in if condition #143: FILE: hw/audio/fmopl.c:634: + if( (VIB_TABLE = g_malloc(VIB_ENT*2 *sizeof(INT32))) == NULL) ERROR: code indent should never use tabs #152: FILE: hw/audio/fmopl.c:1223: +^Iptr = g_malloc(state_size);$ ERROR: code indent should never use tabs #226: FILE: slirp/mbuf.c:74: +^I^Im = (struct mbuf *)g_malloc(SLIRP_MSIZE);$ ERROR: unnecessary cast may hide bugs, use g_new instead #226: FILE: slirp/mbuf.c:74: + m = (struct mbuf *)g_malloc(SLIRP_MSIZE); ERROR: code indent should never use tabs #235: FILE: slirp/mbuf.c:168: +^I dat = (char *)g_malloc(size);$ ERROR: unnecessary cast may hide bugs, use g_new instead #235: FILE: slirp/mbuf.c:168: + dat = (char *)g_malloc(size); WARNING: line over 80 characters #248: FILE: slirp/sbuf.c:55: + sb->sb_wptr = sb->sb_rptr = sb->sb_data = (char *)g_malloc(size); ERROR: code indent should never use tabs #248: FILE: slirp/sbuf.c:55: +^I^Isb->sb_wptr = sb->sb_rptr = sb->sb_data = (char *)g_malloc(size);$ ERROR: unnecessary cast may hide bugs, use g_new instead #248: FILE: slirp/sbuf.c:55: + sb->sb_wptr = sb->sb_rptr = sb->sb_data = (char *)g_malloc(size); ERROR: unnecessary cast may hide bugs, use g_new instead #261: FILE: slirp/socket.c:51: + so = (struct socket *)g_malloc(sizeof(struct socket)); ERROR: code indent should never use tabs #274: FILE: slirp/tcp_subr.c:250: +^Itp = (struct tcpcb *)g_malloc(sizeof(*tp));$ ERROR: unnecessary cast may hide bugs, use g_new instead #274: FILE: slirp/tcp_subr.c:250: + tp = (struct tcpcb *)g_malloc(sizeof(*tp)); ERROR: space prohibited between function name and open parenthesis '(' #304: FILE: tests/tcg/cris/check_openpf1.c:20: + fnam = g_malloc (strlen (argv[0]) + 2); ERROR: space prohibited between function name and open parenthesis '(' #304: FILE: tests/tcg/cris/check_openpf1.c:20: + fnam = g_malloc (strlen (argv[0]) + 2); ERROR: code indent should never use tabs #335: FILE: tests/tcg/test-mmap.c:452: +^Idummybuf = g_malloc (pagesize);$ ERROR: space prohibited between function name and open parenthesis '(' #335: FILE: tests/tcg/test-mmap.c:452: + dummybuf = g_malloc (pagesize); ERROR: code indent should never use tabs #374: FILE: util/envlist.c:28: +^Iif ((envlist = g_malloc(sizeof (*envlist))) == NULL)$ ERROR: space prohibited between function name and open parenthesis '(' #374: FILE: util/envlist.c:28: + if ((envlist = g_malloc(sizeof (*envlist))) == NULL) ERROR: do not use assignment in if condition #374: FILE: util/envlist.c:28: + if ((envlist = g_malloc(sizeof (*envlist))) == NULL) ERROR: braces {} are necessary for all arms of this statement #374: FILE: util/envlist.c:28: + if ((envlist = g_malloc(sizeof (*envlist))) == NULL) [...] ERROR: code indent should never use tabs #383: FILE: util/envlist.c:164: +^Iif ((entry = g_malloc(sizeof (*entry))) == NULL)$ ERROR: space prohibited between function name and open parenthesis '(' #383: FILE: util/envlist.c:164: + if ((entry = g_malloc(sizeof (*entry))) == NULL) ERROR: do not use assignment in if condition #383: FILE: util/envlist.c:164: + if ((entry = g_malloc(sizeof (*entry))) == NULL) ERROR: code indent should never use tabs #392: FILE: util/envlist.c:228: +^Ipenv = env = g_malloc((envlist->el_count + 1) * sizeof (char *));$ ERROR: space prohibited between function name and open parenthesis '(' #392: FILE: util/envlist.c:228: + penv = env = g_malloc((envlist->el_count + 1) * sizeof (char *)); ERROR: Missing Signed-off-by: line(s) total: 59 errors, 1 warnings, 273 lines checked Your patch has style problems, please review. If any of these errors are false positives report them to the maintainer, see CHECKPATCH in MAINTAINERS. === OUTPUT END === Test command exited with code: 1 --- Email generated automatically by Patchew [http://patchew.org/]. Please send your feedback to [email protected]
