All of lore.kernel.org
 help / color / mirror / Atom feed
* [RESEND PATCH 0/2] scripts: small fixes
@ 2016-04-12 15:18 Maxim Zhukov
  2016-04-12 15:18 ` [PATCH 1/2] scripts: genksyms: fix resource leak Maxim Zhukov
                   ` (2 more replies)
  0 siblings, 3 replies; 9+ messages in thread
From: Maxim Zhukov @ 2016-04-12 15:18 UTC (permalink / raw)
  To: Rob Herring; +Cc: Frank Rowand, Grant Likely, linux-kernel

[PATCH 1/2] scripts: genksyms: fix resource leak
[PATCH 2/2] scripts: dtc: fix memory leak after realloc

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [PATCH 1/2] scripts: genksyms: fix resource leak
  2016-04-12 15:18 [RESEND PATCH 0/2] scripts: small fixes Maxim Zhukov
@ 2016-04-12 15:18 ` Maxim Zhukov
  2016-04-12 15:18 ` [PATCH 2/2] scripts: dtc: fix memory leak after realloc Maxim Zhukov
  2016-04-12 15:39 ` [RESEND PATCH 0/2] scripts: small fixes Rob Herring
  2 siblings, 0 replies; 9+ messages in thread
From: Maxim Zhukov @ 2016-04-12 15:18 UTC (permalink / raw)
  To: Rob Herring; +Cc: Frank Rowand, Grant Likely, linux-kernel, Maxim Zhukov

This commit fixed resource leak at func main

Signed-off-by: Maxim Zhukov <mussitantesmortem@gmail.com>
---
 scripts/genksyms/genksyms.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/scripts/genksyms/genksyms.c b/scripts/genksyms/genksyms.c
index dafaf96..06121ce 100644
--- a/scripts/genksyms/genksyms.c
+++ b/scripts/genksyms/genksyms.c
@@ -873,5 +873,8 @@ int main(int argc, char **argv)
 			(double)nsyms / (double)HASH_BUCKETS);
 	}
 
+	if (dumpfile)
+		fclose(dumpfile);
+
 	return errors != 0;
 }
-- 
2.7.1.1.g3617aa0

^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [PATCH 2/2] scripts: dtc: fix memory leak after realloc
  2016-04-12 15:18 [RESEND PATCH 0/2] scripts: small fixes Maxim Zhukov
  2016-04-12 15:18 ` [PATCH 1/2] scripts: genksyms: fix resource leak Maxim Zhukov
@ 2016-04-12 15:18 ` Maxim Zhukov
  2016-04-12 15:39 ` [RESEND PATCH 0/2] scripts: small fixes Rob Herring
  2 siblings, 0 replies; 9+ messages in thread
From: Maxim Zhukov @ 2016-04-12 15:18 UTC (permalink / raw)
  To: Rob Herring; +Cc: Frank Rowand, Grant Likely, linux-kernel, Maxim Zhukov

This commit fixed memory leak after errors realloc.

Signed-off-by: Maxim Zhukov <mussitantesmortem@gmail.com>
---
 scripts/dtc/fdtput.c | 10 +++++++---
 1 file changed, 7 insertions(+), 3 deletions(-)

diff --git a/scripts/dtc/fdtput.c b/scripts/dtc/fdtput.c
index f2197f5..1042319 100644
--- a/scripts/dtc/fdtput.c
+++ b/scripts/dtc/fdtput.c
@@ -75,8 +75,9 @@ static int encode_value(struct display_info *disp, char **arg, int arg_count,
 	char *ptr;		/* pointer to current value position */
 	int len;		/* length of this cell/string/byte */
 	int ival;
-	int upto;	/* the number of bytes we have written to buf */
+	int upto;		/* the number of bytes we have written to buf */
 	char fmt[3];
+	void *save_ptr = NULL;	/* save pointer to realloc */
 
 	upto = 0;
 
@@ -96,12 +97,15 @@ static int encode_value(struct display_info *disp, char **arg, int arg_count,
 		/* enlarge our value buffer by a suitable margin if needed */
 		if (upto + len > value_size) {
 			value_size = (upto + len) + 500;
-			value = realloc(value, value_size);
-			if (!value) {
+			void *save_ptr = realloc(value, value_size);
+
+			if (!save_ptr) {
+				free(value);
 				fprintf(stderr, "Out of mmory: cannot alloc "
 					"%d bytes\n", value_size);
 				return -1;
 			}
+			value = save_ptr;
 		}
 
 		ptr = value + upto;
-- 
2.7.1.1.g3617aa0

^ permalink raw reply related	[flat|nested] 9+ messages in thread

* Re: [RESEND PATCH 0/2] scripts: small fixes
  2016-04-12 15:18 [RESEND PATCH 0/2] scripts: small fixes Maxim Zhukov
  2016-04-12 15:18 ` [PATCH 1/2] scripts: genksyms: fix resource leak Maxim Zhukov
  2016-04-12 15:18 ` [PATCH 2/2] scripts: dtc: fix memory leak after realloc Maxim Zhukov
@ 2016-04-12 15:39 ` Rob Herring
  2016-04-12 15:40   ` Rob Herring
  2 siblings, 1 reply; 9+ messages in thread
From: Rob Herring @ 2016-04-12 15:39 UTC (permalink / raw)
  To: Maxim Zhukov; +Cc: Frank Rowand, Grant Likely, linux-kernel

On Tue, Apr 12, 2016 at 10:18 AM, Maxim Zhukov
<mussitantesmortem@gmail.com> wrote:
> [PATCH 1/2] scripts: genksyms: fix resource leak
> [PATCH 2/2] scripts: dtc: fix memory leak after realloc

scripts/dtc is just an import of upstream dtc[1]. So your patches need
to be against that and sent to devicetree-compiler@vger.kernel.org.
Once they are in, I can do a new import.

Rob

[1] git://git.kernel.org/pub/scm/utils/dtc/dtc.git

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [RESEND PATCH 0/2] scripts: small fixes
  2016-04-12 15:39 ` [RESEND PATCH 0/2] scripts: small fixes Rob Herring
@ 2016-04-12 15:40   ` Rob Herring
  0 siblings, 0 replies; 9+ messages in thread
From: Rob Herring @ 2016-04-12 15:40 UTC (permalink / raw)
  To: Maxim Zhukov; +Cc: Frank Rowand, Grant Likely, linux-kernel

On Tue, Apr 12, 2016 at 10:39 AM, Rob Herring <robh+dt@kernel.org> wrote:
> On Tue, Apr 12, 2016 at 10:18 AM, Maxim Zhukov
> <mussitantesmortem@gmail.com> wrote:
>> [PATCH 1/2] scripts: genksyms: fix resource leak
>> [PATCH 2/2] scripts: dtc: fix memory leak after realloc
>
> scripts/dtc is just an import of upstream dtc[1]. So your patches need
> to be against that and sent to devicetree-compiler@vger.kernel.org.
> Once they are in, I can do a new import.

Sorry, that's only for patch 2.

Rob

>
> Rob
>
> [1] git://git.kernel.org/pub/scm/utils/dtc/dtc.git

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH 1/2] scripts: genksyms: fix resource leak
  2016-04-12 14:03 [PATCH 1/2] scripts: genksyms: fix resource leak Maxim Zhukov
  2016-04-12 14:31 ` kbuild test robot
  2016-04-12 14:39 ` kbuild test robot
@ 2016-04-12 14:39 ` kbuild test robot
  2 siblings, 0 replies; 9+ messages in thread
From: kbuild test robot @ 2016-04-12 14:39 UTC (permalink / raw)
  To: Maxim Zhukov
  Cc: kbuild-all, Rob Herring, Frank Rowand, Grant Likely,
	linux-kernel, Maxim Zhukov

[-- Attachment #1: Type: text/plain, Size: 17337 bytes --]

Hi Maxim,

[auto build test ERROR on robh/for-next]
[also build test ERROR on v4.6-rc3 next-20160412]
[if your patch is applied to the wrong git tree, please drop us a note to help improving the system]

url:    https://github.com/0day-ci/linux/commits/Maxim-Zhukov/scripts-genksyms-fix-resource-leak/20160412-221051
base:   https://git.kernel.org/pub/scm/linux/kernel/git/robh/linux for-next
config: cris-allmodconfig (attached as .config)
reproduce:
        wget https://git.kernel.org/cgit/linux/kernel/git/wfg/lkp-tests.git/plain/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # save the attached .config to linux build tree
        make.cross ARCH=cris 

All errors (new ones prefixed by >>):

>> /bin/bash: line 1: 35964 Done                    cris-linux-gcc -E -D__GENKSYMS__ -Wp,-MD,drivers/devfreq/.devfreq.o.d -nostdinc -isystem /usr/local/gcc-4.6.3-nolibc/cris-linux/bin/../lib/gcc/cris-linux/4.6.3/include -Iarch/cris/include -Iarch/cris/include/generated/uapi -Iarch/cris/include/generated -Iinclude -Iinclude -Iarch/cris/include/uapi -Iarch/cris/include/generated/uapi -Iinclude/uapi -Iinclude/generated/uapi -include include/linux/kconfig.h -Idrivers/devfreq -Idrivers/devfreq -D__KERNEL__ -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/mach -Iarch/cris/include/arch-v10/mach-fs/mach -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Wno-format-security -std=gnu89 -mlinux -march=v10 -pipe -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/mach -Iarch/cris/include/arch-v10/mach-fs/mach -g -fno-omit-frame-pointer -fno-delete-null-pointer-checks -Os -fno-reorder-blocks -fno-ipa-cp-clone -fno-partial-inlining -Wframe-larger-than=1024 -fno-stack-protector -Wno-unused-but-set-variable -fno-omit-frame-pointer -fno-optimize-sibling-calls -fno-var-tracking-assignments -fno-inline-functions-called-once -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-overflow -fconserve-stack -Werror=implicit-int -Werror=strict-prototypes -DCC_HAVE_ASM_GOTO -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(devfreq)" -D"KBUILD_MODNAME=KBUILD_STR(devfreq)" drivers/devfreq/devfreq.c
        35966 Segmentation fault      | scripts/genksyms/genksyms -r /dev/null > drivers/devfreq/.tmp_devfreq.ver
--
>> /bin/bash: line 1: 38095 Done                    cris-linux-gcc -E -D__GENKSYMS__ -Wp,-MD,drivers/gpu/drm/.drm_atomic_helper.o.d -nostdinc -isystem /usr/local/gcc-4.6.3-nolibc/cris-linux/bin/../lib/gcc/cris-linux/4.6.3/include -Iarch/cris/include -Iarch/cris/include/generated/uapi -Iarch/cris/include/generated -Iinclude -Iinclude -Iarch/cris/include/uapi -Iarch/cris/include/generated/uapi -Iinclude/uapi -Iinclude/generated/uapi -include include/linux/kconfig.h -Idrivers/gpu/drm -Idrivers/gpu/drm -D__KERNEL__ -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/mach -Iarch/cris/include/arch-v10/mach-fs/mach -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Wno-format-security -std=gnu89 -mlinux -march=v10 -pipe -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/mach -Iarch/cris/include/arch-v10/mach-fs/mach -g -fno-omit-frame-pointer -fno-delete-null-pointer-checks -Os -fno-reorder-blocks -fno-ipa-cp-clone -fno-partial-inlining -Wframe-larger-than=1024 -fno-stack-protector -Wno-unused-but-set-variable -fno-omit-frame-pointer -fno-optimize-sibling-calls -fno-var-tracking-assignments -fno-inline-functions-called-once -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-overflow -fconserve-stack -Werror=implicit-int -Werror=strict-prototypes -DCC_HAVE_ASM_GOTO -DMODULE -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(drm_atomic_helper)" -D"KBUILD_MODNAME=KBUILD_STR(drm_kms_helper)" drivers/gpu/drm/drm_atomic_helper.c
        38096 Segmentation fault      | scripts/genksyms/genksyms -r /dev/null > drivers/gpu/drm/.tmp_drm_atomic_helper.ver
--
>> /bin/bash: line 1: 36678 Done                    cris-linux-gcc -E -D__GENKSYMS__ -Wp,-MD,drivers/gpu/drm/.drm_cache.o.d -nostdinc -isystem /usr/local/gcc-4.6.3-nolibc/cris-linux/bin/../lib/gcc/cris-linux/4.6.3/include -Iarch/cris/include -Iarch/cris/include/generated/uapi -Iarch/cris/include/generated -Iinclude -Iinclude -Iarch/cris/include/uapi -Iarch/cris/include/generated/uapi -Iinclude/uapi -Iinclude/generated/uapi -include include/linux/kconfig.h -Idrivers/gpu/drm -Idrivers/gpu/drm -D__KERNEL__ -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/mach -Iarch/cris/include/arch-v10/mach-fs/mach -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Wno-format-security -std=gnu89 -mlinux -march=v10 -pipe -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/mach -Iarch/cris/include/arch-v10/mach-fs/mach -g -fno-omit-frame-pointer -fno-delete-null-pointer-checks -Os -fno-reorder-blocks -fno-ipa-cp-clone -fno-partial-inlining -Wframe-larger-than=1024 -fno-stack-protector -Wno-unused-but-set-variable -fno-omit-frame-pointer -fno-optimize-sibling-calls -fno-var-tracking-assignments -fno-inline-functions-called-once -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-overflow -fconserve-stack -Werror=implicit-int -Werror=strict-prototypes -DCC_HAVE_ASM_GOTO -DMODULE -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(drm_cache)" -D"KBUILD_MODNAME=KBUILD_STR(drm)" drivers/gpu/drm/drm_cache.c
        36679 Segmentation fault      | scripts/genksyms/genksyms -r /dev/null > drivers/gpu/drm/.tmp_drm_cache.ver
--
>> /bin/bash: line 1: 38621 Done                    cris-linux-gcc -E -D__GENKSYMS__ -Wp,-MD,drivers/gpu/drm/.drm_irq.o.d -nostdinc -isystem /usr/local/gcc-4.6.3-nolibc/cris-linux/bin/../lib/gcc/cris-linux/4.6.3/include -Iarch/cris/include -Iarch/cris/include/generated/uapi -Iarch/cris/include/generated -Iinclude -Iinclude -Iarch/cris/include/uapi -Iarch/cris/include/generated/uapi -Iinclude/uapi -Iinclude/generated/uapi -include include/linux/kconfig.h -Idrivers/gpu/drm -Idrivers/gpu/drm -D__KERNEL__ -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/mach -Iarch/cris/include/arch-v10/mach-fs/mach -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Wno-format-security -std=gnu89 -mlinux -march=v10 -pipe -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/mach -Iarch/cris/include/arch-v10/mach-fs/mach -g -fno-omit-frame-pointer -fno-delete-null-pointer-checks -Os -fno-reorder-blocks -fno-ipa-cp-clone -fno-partial-inlining -Wframe-larger-than=1024 -fno-stack-protector -Wno-unused-but-set-variable -fno-omit-frame-pointer -fno-optimize-sibling-calls -fno-var-tracking-assignments -fno-inline-functions-called-once -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-overflow -fconserve-stack -Werror=implicit-int -Werror=strict-prototypes -DCC_HAVE_ASM_GOTO -DMODULE -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(drm_irq)" -D"KBUILD_MODNAME=KBUILD_STR(drm)" drivers/gpu/drm/drm_irq.c
        38623 Segmentation fault      | scripts/genksyms/genksyms -r /dev/null > drivers/gpu/drm/.tmp_drm_irq.ver
--
>> /bin/bash: line 1: 38856 Done                    cris-linux-gcc -E -D__GENKSYMS__ -Wp,-MD,drivers/gpu/drm/.drm_sysfs.o.d -nostdinc -isystem /usr/local/gcc-4.6.3-nolibc/cris-linux/bin/../lib/gcc/cris-linux/4.6.3/include -Iarch/cris/include -Iarch/cris/include/generated/uapi -Iarch/cris/include/generated -Iinclude -Iinclude -Iarch/cris/include/uapi -Iarch/cris/include/generated/uapi -Iinclude/uapi -Iinclude/generated/uapi -include include/linux/kconfig.h -Idrivers/gpu/drm -Idrivers/gpu/drm -D__KERNEL__ -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/mach -Iarch/cris/include/arch-v10/mach-fs/mach -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Wno-format-security -std=gnu89 -mlinux -march=v10 -pipe -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/mach -Iarch/cris/include/arch-v10/mach-fs/mach -g -fno-omit-frame-pointer -fno-delete-null-pointer-checks -Os -fno-reorder-blocks -fno-ipa-cp-clone -fno-partial-inlining -Wframe-larger-than=1024 -fno-stack-protector -Wno-unused-but-set-variable -fno-omit-frame-pointer -fno-optimize-sibling-calls -fno-var-tracking-assignments -fno-inline-functions-called-once -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-overflow -fconserve-stack -Werror=implicit-int -Werror=strict-prototypes -DCC_HAVE_ASM_GOTO -DMODULE -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(drm_sysfs)" -D"KBUILD_MODNAME=KBUILD_STR(drm)" drivers/gpu/drm/drm_sysfs.c
        38857 Segmentation fault      | scripts/genksyms/genksyms -r /dev/null > drivers/gpu/drm/.tmp_drm_sysfs.ver
--
   drivers/gpu/drm/drm_crtc.c: In function 'drm_plane_index':
   drivers/gpu/drm/drm_crtc.c:1381:1: warning: control reaches end of non-void function [-Wreturn-type]
   drivers/gpu/drm/drm_crtc.c: In function 'drm_encoder_index':
   drivers/gpu/drm/drm_crtc.c:1170:1: warning: control reaches end of non-void function [-Wreturn-type]
   drivers/gpu/drm/drm_crtc.c: In function 'drm_crtc_index':
   drivers/gpu/drm/drm_crtc.c:784:1: warning: control reaches end of non-void function [-Wreturn-type]
>> /bin/bash: line 1: 39945 Done                    cris-linux-gcc -E -D__GENKSYMS__ -Wp,-MD,drivers/gpu/drm/.drm_crtc.o.d -nostdinc -isystem /usr/local/gcc-4.6.3-nolibc/cris-linux/bin/../lib/gcc/cris-linux/4.6.3/include -Iarch/cris/include -Iarch/cris/include/generated/uapi -Iarch/cris/include/generated -Iinclude -Iinclude -Iarch/cris/include/uapi -Iarch/cris/include/generated/uapi -Iinclude/uapi -Iinclude/generated/uapi -include include/linux/kconfig.h -Idrivers/gpu/drm -Idrivers/gpu/drm -D__KERNEL__ -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/mach -Iarch/cris/include/arch-v10/mach-fs/mach -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Wno-format-security -std=gnu89 -mlinux -march=v10 -pipe -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/mach -Iarch/cris/include/arch-v10/mach-fs/mach -g -fno-omit-frame-pointer -fno-delete-null-pointer-checks -Os -fno-reorder-blocks -fno-ipa-cp-clone -fno-partial-inlining -Wframe-larger-than=1024 -fno-stack-protector -Wno-unused-but-set-variable -fno-omit-frame-pointer -fno-optimize-sibling-calls -fno-var-tracking-assignments -fno-inline-functions-called-once -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-overflow -fconserve-stack -Werror=implicit-int -Werror=strict-prototypes -DCC_HAVE_ASM_GOTO -DMODULE -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(drm_crtc)" -D"KBUILD_MODNAME=KBUILD_STR(drm)" drivers/gpu/drm/drm_crtc.c
        39946 Segmentation fault      | scripts/genksyms/genksyms -r /dev/null > drivers/gpu/drm/.tmp_drm_crtc.ver
--
>> /bin/bash: line 1: 39445 Done                    cris-linux-gcc -E -D__GENKSYMS__ -Wp,-MD,drivers/gpu/drm/.drm_edid.o.d -nostdinc -isystem /usr/local/gcc-4.6.3-nolibc/cris-linux/bin/../lib/gcc/cris-linux/4.6.3/include -Iarch/cris/include -Iarch/cris/include/generated/uapi -Iarch/cris/include/generated -Iinclude -Iinclude -Iarch/cris/include/uapi -Iarch/cris/include/generated/uapi -Iinclude/uapi -Iinclude/generated/uapi -include include/linux/kconfig.h -Idrivers/gpu/drm -Idrivers/gpu/drm -D__KERNEL__ -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/mach -Iarch/cris/include/arch-v10/mach-fs/mach -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Wno-format-security -std=gnu89 -mlinux -march=v10 -pipe -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/uapi/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/arch-v10 -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/uapi/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/arch -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/ -Iarch/cris/include/arch-v10/mach-fs/mach -Iarch/cris/include/arch-v10/mach-fs/mach -g -fno-omit-frame-pointer -fno-delete-null-pointer-checks -Os -fno-reorder-blocks -fno-ipa-cp-clone -fno-partial-inlining -Wframe-larger-than=1024 -fno-stack-protector -Wno-unused-but-set-variable -fno-omit-frame-pointer -fno-optimize-sibling-calls -fno-var-tracking-assignments -fno-inline-functions-called-once -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-overflow -fconserve-stack -Werror=implicit-int -Werror=strict-prototypes -DCC_HAVE_ASM_GOTO -DMODULE -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(drm_edid)" -D"KBUILD_MODNAME=KBUILD_STR(drm)" drivers/gpu/drm/drm_edid.c
        39446 Segmentation fault      | scripts/genksyms/genksyms -r /dev/null > drivers/gpu/drm/.tmp_drm_edid.ver

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

[-- Attachment #2: .config.gz --]
[-- Type: application/octet-stream, Size: 38107 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH 1/2] scripts: genksyms: fix resource leak
  2016-04-12 14:03 [PATCH 1/2] scripts: genksyms: fix resource leak Maxim Zhukov
  2016-04-12 14:31 ` kbuild test robot
@ 2016-04-12 14:39 ` kbuild test robot
  2016-04-12 14:39 ` kbuild test robot
  2 siblings, 0 replies; 9+ messages in thread
From: kbuild test robot @ 2016-04-12 14:39 UTC (permalink / raw)
  To: Maxim Zhukov
  Cc: kbuild-all, Rob Herring, Frank Rowand, Grant Likely,
	linux-kernel, Maxim Zhukov

[-- Attachment #1: Type: text/plain, Size: 20373 bytes --]

Hi Maxim,

[auto build test ERROR on robh/for-next]
[also build test ERROR on v4.6-rc3 next-20160412]
[if your patch is applied to the wrong git tree, please drop us a note to help improving the system]

url:    https://github.com/0day-ci/linux/commits/Maxim-Zhukov/scripts-genksyms-fix-resource-leak/20160412-221051
base:   https://git.kernel.org/pub/scm/linux/kernel/git/robh/linux for-next
config: i386-randconfig-x003-201615 (attached as .config)
reproduce:
        # save the attached .config to linux build tree
        make ARCH=i386 

All errors (new ones prefixed by >>):

>> /bin/bash: line 1: 60775 Done                    gcc-5 -E -D__GENKSYMS__ -Wp,-MD,arch/x86/events/intel/.core.o.d -nostdinc -isystem /usr/lib/gcc/x86_64-linux-gnu/5/include -Iarch/x86/include -Iarch/x86/include/generated/uapi -Iarch/x86/include/generated -Iinclude -Iinclude -Iarch/x86/include/uapi -Iarch/x86/include/generated/uapi -Iinclude/uapi -Iinclude/generated/uapi -include include/linux/kconfig.h -Iarch/x86/events -Iarch/x86/events -D__KERNEL__ -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Wno-format-security -std=gnu89 -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -mno-avx -m32 -msoft-float -mregparm=3 -freg-struct-return -fno-pic -mpreferred-stack-boundary=2 -march=i686 -mtune=generic -Wa,-mtune=generic32 -ffreestanding -DCONFIG_AS_CFI=1 -DCONFIG_AS_CFI_SIGNAL_FRAME=1 -DCONFIG_AS_CFI_SECTIONS=1 -DCONFIG_AS_SSSE3=1 -DCONFIG_AS_CRC32=1 -DCONFIG_AS_AVX=1 -DCONFIG_AS_AVX2=1 -DCONFIG_AS_SHA1_NI=1 -DCONFIG_AS_SHA256_NI=1 -pipe -Wno-sign-compare -fno-asynchronous-unwind-tables -fno-delete-null-pointer-checks -O2 --param=allow-store-data-races=0 -fno-reorder-blocks -fno-ipa-cp-clone -fno-partial-inlining -Wframe-larger-than=1024 -fno-stack-protector -Wno-unused-but-set-variable -fno-omit-frame-pointer -fno-optimize-sibling-calls -fno-var-tracking-assignments -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-overflow -fconserve-stack -Werror=implicit-int -Werror=strict-prototypes -Werror=date-time -Werror=incompatible-pointer-types -DCC_HAVE_ASM_GOTO -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(core)" -D"KBUILD_MODNAME=KBUILD_STR(core)" arch/x86/events/intel/core.c
        60776 Segmentation fault      | scripts/genksyms/genksyms -r /dev/null > arch/x86/events/intel/.tmp_core.ver
--
>> /bin/bash: line 1: 61910 Done                    gcc-5 -E -D__GENKSYMS__ -Wp,-MD,arch/x86/kernel/.dumpstack.o.d -nostdinc -isystem /usr/lib/gcc/x86_64-linux-gnu/5/include -Iarch/x86/include -Iarch/x86/include/generated/uapi -Iarch/x86/include/generated -Iinclude -Iinclude -Iarch/x86/include/uapi -Iarch/x86/include/generated/uapi -Iinclude/uapi -Iinclude/generated/uapi -include include/linux/kconfig.h -Iarch/x86/kernel -Iarch/x86/kernel -D__KERNEL__ -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Wno-format-security -std=gnu89 -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -mno-avx -m32 -msoft-float -mregparm=3 -freg-struct-return -fno-pic -mpreferred-stack-boundary=2 -march=i686 -mtune=generic -Wa,-mtune=generic32 -ffreestanding -DCONFIG_AS_CFI=1 -DCONFIG_AS_CFI_SIGNAL_FRAME=1 -DCONFIG_AS_CFI_SECTIONS=1 -DCONFIG_AS_SSSE3=1 -DCONFIG_AS_CRC32=1 -DCONFIG_AS_AVX=1 -DCONFIG_AS_AVX2=1 -DCONFIG_AS_SHA1_NI=1 -DCONFIG_AS_SHA256_NI=1 -pipe -Wno-sign-compare -fno-asynchronous-unwind-tables -fno-delete-null-pointer-checks -O2 --param=allow-store-data-races=0 -fno-reorder-blocks -fno-ipa-cp-clone -fno-partial-inlining -Wframe-larger-than=1024 -fno-stack-protector -Wno-unused-but-set-variable -fno-omit-frame-pointer -fno-optimize-sibling-calls -fno-var-tracking-assignments -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-overflow -fconserve-stack -Werror=implicit-int -Werror=strict-prototypes -Werror=date-time -Werror=incompatible-pointer-types -DCC_HAVE_ASM_GOTO -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(dumpstack)" -D"KBUILD_MODNAME=KBUILD_STR(dumpstack)" arch/x86/kernel/dumpstack.c
        61911 Segmentation fault      | scripts/genksyms/genksyms -r /dev/null > arch/x86/kernel/.tmp_dumpstack.ver
--
>> /bin/bash: line 1: 73525 Done                    gcc-5 -E -D__GENKSYMS__ -Wp,-MD,arch/x86/kernel/.kvm.o.d -nostdinc -isystem /usr/lib/gcc/x86_64-linux-gnu/5/include -Iarch/x86/include -Iarch/x86/include/generated/uapi -Iarch/x86/include/generated -Iinclude -Iinclude -Iarch/x86/include/uapi -Iarch/x86/include/generated/uapi -Iinclude/uapi -Iinclude/generated/uapi -include include/linux/kconfig.h -Iarch/x86/kernel -Iarch/x86/kernel -D__KERNEL__ -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Wno-format-security -std=gnu89 -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -mno-avx -m32 -msoft-float -mregparm=3 -freg-struct-return -fno-pic -mpreferred-stack-boundary=2 -march=i686 -mtune=generic -Wa,-mtune=generic32 -ffreestanding -DCONFIG_AS_CFI=1 -DCONFIG_AS_CFI_SIGNAL_FRAME=1 -DCONFIG_AS_CFI_SECTIONS=1 -DCONFIG_AS_SSSE3=1 -DCONFIG_AS_CRC32=1 -DCONFIG_AS_AVX=1 -DCONFIG_AS_AVX2=1 -DCONFIG_AS_SHA1_NI=1 -DCONFIG_AS_SHA256_NI=1 -pipe -Wno-sign-compare -fno-asynchronous-unwind-tables -fno-delete-null-pointer-checks -O2 --param=allow-store-data-races=0 -fno-reorder-blocks -fno-ipa-cp-clone -fno-partial-inlining -Wframe-larger-than=1024 -fno-stack-protector -Wno-unused-but-set-variable -fno-omit-frame-pointer -fno-optimize-sibling-calls -fno-var-tracking-assignments -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-overflow -fconserve-stack -Werror=implicit-int -Werror=strict-prototypes -Werror=date-time -Werror=incompatible-pointer-types -DCC_HAVE_ASM_GOTO -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(kvm)" -D"KBUILD_MODNAME=KBUILD_STR(kvm)" arch/x86/kernel/kvm.c
        73526 Segmentation fault      | scripts/genksyms/genksyms -r /dev/null > arch/x86/kernel/.tmp_kvm.ver
--
>> /bin/bash: line 1: 59954 Done                    gcc-5 -E -D__GENKSYMS__ -Wp,-MD,arch/x86/mm/.init.o.d -nostdinc -isystem /usr/lib/gcc/x86_64-linux-gnu/5/include -Iarch/x86/include -Iarch/x86/include/generated/uapi -Iarch/x86/include/generated -Iinclude -Iinclude -Iarch/x86/include/uapi -Iarch/x86/include/generated/uapi -Iinclude/uapi -Iinclude/generated/uapi -include include/linux/kconfig.h -Iarch/x86/mm -Iarch/x86/mm -D__KERNEL__ -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Wno-format-security -std=gnu89 -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -mno-avx -m32 -msoft-float -mregparm=3 -freg-struct-return -fno-pic -mpreferred-stack-boundary=2 -march=i686 -mtune=generic -Wa,-mtune=generic32 -ffreestanding -DCONFIG_AS_CFI=1 -DCONFIG_AS_CFI_SIGNAL_FRAME=1 -DCONFIG_AS_CFI_SECTIONS=1 -DCONFIG_AS_SSSE3=1 -DCONFIG_AS_CRC32=1 -DCONFIG_AS_AVX=1 -DCONFIG_AS_AVX2=1 -DCONFIG_AS_SHA1_NI=1 -DCONFIG_AS_SHA256_NI=1 -pipe -Wno-sign-compare -fno-asynchronous-unwind-tables -fno-delete-null-pointer-checks -O2 --param=allow-store-data-races=0 -fno-reorder-blocks -fno-ipa-cp-clone -fno-partial-inlining -Wframe-larger-than=1024 -fno-stack-protector -Wno-unused-but-set-variable -fno-omit-frame-pointer -fno-optimize-sibling-calls -fno-var-tracking-assignments -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-overflow -fconserve-stack -Werror=implicit-int -Werror=strict-prototypes -Werror=date-time -Werror=incompatible-pointer-types -DCC_HAVE_ASM_GOTO -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(init)" -D"KBUILD_MODNAME=KBUILD_STR(init)" arch/x86/mm/init.c
        59955 Segmentation fault      | scripts/genksyms/genksyms -r /dev/null > arch/x86/mm/.tmp_init.ver
--
>> /bin/bash: line 1: 60306 Done                    gcc-5 -E -D__GENKSYMS__ -Wp,-MD,arch/x86/mm/.init_32.o.d -nostdinc -isystem /usr/lib/gcc/x86_64-linux-gnu/5/include -Iarch/x86/include -Iarch/x86/include/generated/uapi -Iarch/x86/include/generated -Iinclude -Iinclude -Iarch/x86/include/uapi -Iarch/x86/include/generated/uapi -Iinclude/uapi -Iinclude/generated/uapi -include include/linux/kconfig.h -Iarch/x86/mm -Iarch/x86/mm -D__KERNEL__ -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Wno-format-security -std=gnu89 -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -mno-avx -m32 -msoft-float -mregparm=3 -freg-struct-return -fno-pic -mpreferred-stack-boundary=2 -march=i686 -mtune=generic -Wa,-mtune=generic32 -ffreestanding -DCONFIG_AS_CFI=1 -DCONFIG_AS_CFI_SIGNAL_FRAME=1 -DCONFIG_AS_CFI_SECTIONS=1 -DCONFIG_AS_SSSE3=1 -DCONFIG_AS_CRC32=1 -DCONFIG_AS_AVX=1 -DCONFIG_AS_AVX2=1 -DCONFIG_AS_SHA1_NI=1 -DCONFIG_AS_SHA256_NI=1 -pipe -Wno-sign-compare -fno-asynchronous-unwind-tables -fno-delete-null-pointer-checks -O2 --param=allow-store-data-races=0 -fno-reorder-blocks -fno-ipa-cp-clone -fno-partial-inlining -Wframe-larger-than=1024 -fno-stack-protector -Wno-unused-but-set-variable -fno-omit-frame-pointer -fno-optimize-sibling-calls -fno-var-tracking-assignments -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-overflow -fconserve-stack -Werror=implicit-int -Werror=strict-prototypes -Werror=date-time -Werror=incompatible-pointer-types -DCC_HAVE_ASM_GOTO -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(init_32)" -D"KBUILD_MODNAME=KBUILD_STR(init_32)" arch/x86/mm/init_32.c
        60307 Segmentation fault      | scripts/genksyms/genksyms -r /dev/null > arch/x86/mm/.tmp_init_32.ver
--
>> /bin/bash: line 1: 60018 Done                    gcc-5 -E -D__GENKSYMS__ -Wp,-MD,arch/x86/mm/.ioremap.o.d -nostdinc -isystem /usr/lib/gcc/x86_64-linux-gnu/5/include -Iarch/x86/include -Iarch/x86/include/generated/uapi -Iarch/x86/include/generated -Iinclude -Iinclude -Iarch/x86/include/uapi -Iarch/x86/include/generated/uapi -Iinclude/uapi -Iinclude/generated/uapi -include include/linux/kconfig.h -Iarch/x86/mm -Iarch/x86/mm -D__KERNEL__ -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Wno-format-security -std=gnu89 -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -mno-avx -m32 -msoft-float -mregparm=3 -freg-struct-return -fno-pic -mpreferred-stack-boundary=2 -march=i686 -mtune=generic -Wa,-mtune=generic32 -ffreestanding -DCONFIG_AS_CFI=1 -DCONFIG_AS_CFI_SIGNAL_FRAME=1 -DCONFIG_AS_CFI_SECTIONS=1 -DCONFIG_AS_SSSE3=1 -DCONFIG_AS_CRC32=1 -DCONFIG_AS_AVX=1 -DCONFIG_AS_AVX2=1 -DCONFIG_AS_SHA1_NI=1 -DCONFIG_AS_SHA256_NI=1 -pipe -Wno-sign-compare -fno-asynchronous-unwind-tables -fno-delete-null-pointer-checks -O2 --param=allow-store-data-races=0 -fno-reorder-blocks -fno-ipa-cp-clone -fno-partial-inlining -Wframe-larger-than=1024 -fno-stack-protector -Wno-unused-but-set-variable -fno-omit-frame-pointer -fno-optimize-sibling-calls -fno-var-tracking-assignments -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-overflow -fconserve-stack -Werror=implicit-int -Werror=strict-prototypes -Werror=date-time -Werror=incompatible-pointer-types -DCC_HAVE_ASM_GOTO -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(ioremap)" -D"KBUILD_MODNAME=KBUILD_STR(ioremap)" arch/x86/mm/ioremap.c
        60019 Segmentation fault      | scripts/genksyms/genksyms -r /dev/null > arch/x86/mm/.tmp_ioremap.ver
--
>> /bin/bash: line 1: 59695 Done                    gcc-5 -E -D__GENKSYMS__ -Wp,-MD,arch/x86/mm/.extable.o.d -nostdinc -isystem /usr/lib/gcc/x86_64-linux-gnu/5/include -Iarch/x86/include -Iarch/x86/include/generated/uapi -Iarch/x86/include/generated -Iinclude -Iinclude -Iarch/x86/include/uapi -Iarch/x86/include/generated/uapi -Iinclude/uapi -Iinclude/generated/uapi -include include/linux/kconfig.h -Iarch/x86/mm -Iarch/x86/mm -D__KERNEL__ -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Wno-format-security -std=gnu89 -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -mno-avx -m32 -msoft-float -mregparm=3 -freg-struct-return -fno-pic -mpreferred-stack-boundary=2 -march=i686 -mtune=generic -Wa,-mtune=generic32 -ffreestanding -DCONFIG_AS_CFI=1 -DCONFIG_AS_CFI_SIGNAL_FRAME=1 -DCONFIG_AS_CFI_SECTIONS=1 -DCONFIG_AS_SSSE3=1 -DCONFIG_AS_CRC32=1 -DCONFIG_AS_AVX=1 -DCONFIG_AS_AVX2=1 -DCONFIG_AS_SHA1_NI=1 -DCONFIG_AS_SHA256_NI=1 -pipe -Wno-sign-compare -fno-asynchronous-unwind-tables -fno-delete-null-pointer-checks -O2 --param=allow-store-data-races=0 -fno-reorder-blocks -fno-ipa-cp-clone -fno-partial-inlining -Wframe-larger-than=1024 -fno-stack-protector -Wno-unused-but-set-variable -fno-omit-frame-pointer -fno-optimize-sibling-calls -fno-var-tracking-assignments -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-overflow -fconserve-stack -Werror=implicit-int -Werror=strict-prototypes -Werror=date-time -Werror=incompatible-pointer-types -DCC_HAVE_ASM_GOTO -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(extable)" -D"KBUILD_MODNAME=KBUILD_STR(extable)" arch/x86/mm/extable.c
        59696 Segmentation fault      | scripts/genksyms/genksyms -r /dev/null > arch/x86/mm/.tmp_extable.ver
--
>> /bin/bash: line 1: 61083 Done                    gcc-5 -E -D__GENKSYMS__ -Wp,-MD,arch/x86/mm/.pageattr.o.d -nostdinc -isystem /usr/lib/gcc/x86_64-linux-gnu/5/include -Iarch/x86/include -Iarch/x86/include/generated/uapi -Iarch/x86/include/generated -Iinclude -Iinclude -Iarch/x86/include/uapi -Iarch/x86/include/generated/uapi -Iinclude/uapi -Iinclude/generated/uapi -include include/linux/kconfig.h -Iarch/x86/mm -Iarch/x86/mm -D__KERNEL__ -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Wno-format-security -std=gnu89 -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -mno-avx -m32 -msoft-float -mregparm=3 -freg-struct-return -fno-pic -mpreferred-stack-boundary=2 -march=i686 -mtune=generic -Wa,-mtune=generic32 -ffreestanding -DCONFIG_AS_CFI=1 -DCONFIG_AS_CFI_SIGNAL_FRAME=1 -DCONFIG_AS_CFI_SECTIONS=1 -DCONFIG_AS_SSSE3=1 -DCONFIG_AS_CRC32=1 -DCONFIG_AS_AVX=1 -DCONFIG_AS_AVX2=1 -DCONFIG_AS_SHA1_NI=1 -DCONFIG_AS_SHA256_NI=1 -pipe -Wno-sign-compare -fno-asynchronous-unwind-tables -fno-delete-null-pointer-checks -O2 --param=allow-store-data-races=0 -fno-reorder-blocks -fno-ipa-cp-clone -fno-partial-inlining -Wframe-larger-than=1024 -fno-stack-protector -Wno-unused-but-set-variable -fno-omit-frame-pointer -fno-optimize-sibling-calls -fno-var-tracking-assignments -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-overflow -fconserve-stack -Werror=implicit-int -Werror=strict-prototypes -Werror=date-time -Werror=incompatible-pointer-types -DCC_HAVE_ASM_GOTO -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(pageattr)" -D"KBUILD_MODNAME=KBUILD_STR(pageattr)" arch/x86/mm/pageattr.c
        61084 Segmentation fault      | scripts/genksyms/genksyms -r /dev/null > arch/x86/mm/.tmp_pageattr.ver
--
>> /bin/bash: line 1: 60505 Done                    gcc-5 -E -D__GENKSYMS__ -Wp,-MD,arch/x86/mm/.pat.o.d -nostdinc -isystem /usr/lib/gcc/x86_64-linux-gnu/5/include -Iarch/x86/include -Iarch/x86/include/generated/uapi -Iarch/x86/include/generated -Iinclude -Iinclude -Iarch/x86/include/uapi -Iarch/x86/include/generated/uapi -Iinclude/uapi -Iinclude/generated/uapi -include include/linux/kconfig.h -Iarch/x86/mm -Iarch/x86/mm -D__KERNEL__ -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Wno-format-security -std=gnu89 -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -mno-avx -m32 -msoft-float -mregparm=3 -freg-struct-return -fno-pic -mpreferred-stack-boundary=2 -march=i686 -mtune=generic -Wa,-mtune=generic32 -ffreestanding -DCONFIG_AS_CFI=1 -DCONFIG_AS_CFI_SIGNAL_FRAME=1 -DCONFIG_AS_CFI_SECTIONS=1 -DCONFIG_AS_SSSE3=1 -DCONFIG_AS_CRC32=1 -DCONFIG_AS_AVX=1 -DCONFIG_AS_AVX2=1 -DCONFIG_AS_SHA1_NI=1 -DCONFIG_AS_SHA256_NI=1 -pipe -Wno-sign-compare -fno-asynchronous-unwind-tables -fno-delete-null-pointer-checks -O2 --param=allow-store-data-races=0 -fno-reorder-blocks -fno-ipa-cp-clone -fno-partial-inlining -Wframe-larger-than=1024 -fno-stack-protector -Wno-unused-but-set-variable -fno-omit-frame-pointer -fno-optimize-sibling-calls -fno-var-tracking-assignments -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-overflow -fconserve-stack -Werror=implicit-int -Werror=strict-prototypes -Werror=date-time -Werror=incompatible-pointer-types -DCC_HAVE_ASM_GOTO -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(pat)" -D"KBUILD_MODNAME=KBUILD_STR(pat)" arch/x86/mm/pat.c
        60506 Segmentation fault      | scripts/genksyms/genksyms -r /dev/null > arch/x86/mm/.tmp_pat.ver
--
>> /bin/bash: line 1: 60462 Done                    gcc-5 -E -D__GENKSYMS__ -Wp,-MD,arch/x86/mm/.physaddr.o.d -nostdinc -isystem /usr/lib/gcc/x86_64-linux-gnu/5/include -Iarch/x86/include -Iarch/x86/include/generated/uapi -Iarch/x86/include/generated -Iinclude -Iinclude -Iarch/x86/include/uapi -Iarch/x86/include/generated/uapi -Iinclude/uapi -Iinclude/generated/uapi -include include/linux/kconfig.h -Iarch/x86/mm -Iarch/x86/mm -D__KERNEL__ -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Wno-format-security -std=gnu89 -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -mno-avx -m32 -msoft-float -mregparm=3 -freg-struct-return -fno-pic -mpreferred-stack-boundary=2 -march=i686 -mtune=generic -Wa,-mtune=generic32 -ffreestanding -DCONFIG_AS_CFI=1 -DCONFIG_AS_CFI_SIGNAL_FRAME=1 -DCONFIG_AS_CFI_SECTIONS=1 -DCONFIG_AS_SSSE3=1 -DCONFIG_AS_CRC32=1 -DCONFIG_AS_AVX=1 -DCONFIG_AS_AVX2=1 -DCONFIG_AS_SHA1_NI=1 -DCONFIG_AS_SHA256_NI=1 -pipe -Wno-sign-compare -fno-asynchronous-unwind-tables -fno-delete-null-pointer-checks -O2 --param=allow-store-data-races=0 -fno-reorder-blocks -fno-ipa-cp-clone -fno-partial-inlining -Wframe-larger-than=1024 -fno-stack-protector -Wno-unused-but-set-variable -fno-omit-frame-pointer -fno-optimize-sibling-calls -fno-var-tracking-assignments -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-overflow -fconserve-stack -Werror=implicit-int -Werror=strict-prototypes -Werror=date-time -Werror=incompatible-pointer-types -DCC_HAVE_ASM_GOTO -fno-stack-protector -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(physaddr)" -D"KBUILD_MODNAME=KBUILD_STR(physaddr)" arch/x86/mm/physaddr.c
        60463 Segmentation fault      | scripts/genksyms/genksyms -r /dev/null > arch/x86/mm/.tmp_physaddr.ver
--
>> /bin/bash: line 1: 60960 Done                    gcc-5 -E -D__GENKSYMS__ -Wp,-MD,arch/x86/mm/.pgtable_32.o.d -nostdinc -isystem /usr/lib/gcc/x86_64-linux-gnu/5/include -Iarch/x86/include -Iarch/x86/include/generated/uapi -Iarch/x86/include/generated -Iinclude -Iinclude -Iarch/x86/include/uapi -Iarch/x86/include/generated/uapi -Iinclude/uapi -Iinclude/generated/uapi -include include/linux/kconfig.h -Iarch/x86/mm -Iarch/x86/mm -D__KERNEL__ -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Wno-format-security -std=gnu89 -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -mno-avx -m32 -msoft-float -mregparm=3 -freg-struct-return -fno-pic -mpreferred-stack-boundary=2 -march=i686 -mtune=generic -Wa,-mtune=generic32 -ffreestanding -DCONFIG_AS_CFI=1 -DCONFIG_AS_CFI_SIGNAL_FRAME=1 -DCONFIG_AS_CFI_SECTIONS=1 -DCONFIG_AS_SSSE3=1 -DCONFIG_AS_CRC32=1 -DCONFIG_AS_AVX=1 -DCONFIG_AS_AVX2=1 -DCONFIG_AS_SHA1_NI=1 -DCONFIG_AS_SHA256_NI=1 -pipe -Wno-sign-compare -fno-asynchronous-unwind-tables -fno-delete-null-pointer-checks -O2 --param=allow-store-data-races=0 -fno-reorder-blocks -fno-ipa-cp-clone -fno-partial-inlining -Wframe-larger-than=1024 -fno-stack-protector -Wno-unused-but-set-variable -fno-omit-frame-pointer -fno-optimize-sibling-calls -fno-var-tracking-assignments -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-overflow -fconserve-stack -Werror=implicit-int -Werror=strict-prototypes -Werror=date-time -Werror=incompatible-pointer-types -DCC_HAVE_ASM_GOTO -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(pgtable_32)" -D"KBUILD_MODNAME=KBUILD_STR(pgtable_32)" arch/x86/mm/pgtable_32.c
        60961 Segmentation fault      | scripts/genksyms/genksyms -r /dev/null > arch/x86/mm/.tmp_pgtable_32.ver
..

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

[-- Attachment #2: .config.gz --]
[-- Type: application/octet-stream, Size: 30219 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH 1/2] scripts: genksyms: fix resource leak
  2016-04-12 14:03 [PATCH 1/2] scripts: genksyms: fix resource leak Maxim Zhukov
@ 2016-04-12 14:31 ` kbuild test robot
  2016-04-12 14:39 ` kbuild test robot
  2016-04-12 14:39 ` kbuild test robot
  2 siblings, 0 replies; 9+ messages in thread
From: kbuild test robot @ 2016-04-12 14:31 UTC (permalink / raw)
  To: Maxim Zhukov
  Cc: kbuild-all, Rob Herring, Frank Rowand, Grant Likely,
	linux-kernel, Maxim Zhukov

[-- Attachment #1: Type: text/plain, Size: 4822 bytes --]

Hi Maxim,

[auto build test ERROR on robh/for-next]
[also build test ERROR on v4.6-rc3 next-20160412]
[if your patch is applied to the wrong git tree, please drop us a note to help improving the system]

url:    https://github.com/0day-ci/linux/commits/Maxim-Zhukov/scripts-genksyms-fix-resource-leak/20160412-221051
base:   https://git.kernel.org/pub/scm/linux/kernel/git/robh/linux for-next
config: i386-randconfig-x004-201615 (attached as .config)
reproduce:
        # save the attached .config to linux build tree
        make ARCH=i386 

All errors (new ones prefixed by >>):

>> /bin/bash: line 1: 58780 Done                    gcc-5 -E -D__GENKSYMS__ -Wp,-MD,arch/x86/mm/.tlb.o.d -nostdinc -isystem /usr/lib/gcc/x86_64-linux-gnu/5/include -Iarch/x86/include -Iarch/x86/include/generated/uapi -Iarch/x86/include/generated -Iinclude -Iinclude -Iarch/x86/include/uapi -Iarch/x86/include/generated/uapi -Iinclude/uapi -Iinclude/generated/uapi -include include/linux/kconfig.h -Iarch/x86/mm -Iarch/x86/mm -D__KERNEL__ -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Wno-format-security -std=gnu89 -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -mno-avx -m32 -msoft-float -mregparm=3 -freg-struct-return -fno-pic -mpreferred-stack-boundary=2 -march=i686 -Wa,-mtune=generic32 -ffreestanding -DCONFIG_AS_CFI=1 -DCONFIG_AS_CFI_SIGNAL_FRAME=1 -DCONFIG_AS_CFI_SECTIONS=1 -DCONFIG_AS_SSSE3=1 -DCONFIG_AS_CRC32=1 -DCONFIG_AS_AVX=1 -DCONFIG_AS_AVX2=1 -DCONFIG_AS_SHA1_NI=1 -DCONFIG_AS_SHA256_NI=1 -pipe -Wno-sign-compare -fno-asynchronous-unwind-tables -fno-delete-null-pointer-checks -O2 --param=allow-store-data-races=0 -Wframe-larger-than=1024 -fstack-protector -Wno-unused-but-set-variable -fno-omit-frame-pointer -fno-optimize-sibling-calls -fno-var-tracking-assignments -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-overflow -fconserve-stack -Werror=implicit-int -Werror=strict-prototypes -Werror=date-time -Werror=incompatible-pointer-types -DCC_HAVE_ASM_GOTO -fprofile-arcs -ftest-coverage -fsanitize=shift -fsanitize=integer-divide-by-zero -fsanitize=unreachable -fsanitize=vla-bound -fsanitize=null -fsanitize=signed-integer-overflow -fsanitize=bounds -fsanitize=object-size -fsanitize=returns-nonnull-attribute -fsanitize=bool -fsanitize=enum -fsanitize=alignment -Wno-maybe-uninitialized -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(tlb)" -D"KBUILD_MODNAME=KBUILD_STR(tlb)" arch/x86/mm/tlb.c
        58781 Segmentation fault      | scripts/genksyms/genksyms -r /dev/null > arch/x86/mm/.tmp_tlb.ver
--
>> /bin/bash: line 1: 59417 Done                    gcc-5 -E -D__GENKSYMS__ -Wp,-MD,drivers/devfreq/.devfreq.o.d -nostdinc -isystem /usr/lib/gcc/x86_64-linux-gnu/5/include -Iarch/x86/include -Iarch/x86/include/generated/uapi -Iarch/x86/include/generated -Iinclude -Iinclude -Iarch/x86/include/uapi -Iarch/x86/include/generated/uapi -Iinclude/uapi -Iinclude/generated/uapi -include include/linux/kconfig.h -Idrivers/devfreq -Idrivers/devfreq -D__KERNEL__ -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Wno-format-security -std=gnu89 -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -mno-avx -m32 -msoft-float -mregparm=3 -freg-struct-return -fno-pic -mpreferred-stack-boundary=2 -march=i686 -Wa,-mtune=generic32 -ffreestanding -DCONFIG_AS_CFI=1 -DCONFIG_AS_CFI_SIGNAL_FRAME=1 -DCONFIG_AS_CFI_SECTIONS=1 -DCONFIG_AS_SSSE3=1 -DCONFIG_AS_CRC32=1 -DCONFIG_AS_AVX=1 -DCONFIG_AS_AVX2=1 -DCONFIG_AS_SHA1_NI=1 -DCONFIG_AS_SHA256_NI=1 -pipe -Wno-sign-compare -fno-asynchronous-unwind-tables -fno-delete-null-pointer-checks -O2 --param=allow-store-data-races=0 -Wframe-larger-than=1024 -fstack-protector -Wno-unused-but-set-variable -fno-omit-frame-pointer -fno-optimize-sibling-calls -fno-var-tracking-assignments -Wdeclaration-after-statement -Wno-pointer-sign -fno-strict-overflow -fconserve-stack -Werror=implicit-int -Werror=strict-prototypes -Werror=date-time -Werror=incompatible-pointer-types -DCC_HAVE_ASM_GOTO -fprofile-arcs -ftest-coverage -fsanitize=shift -fsanitize=integer-divide-by-zero -fsanitize=unreachable -fsanitize=vla-bound -fsanitize=null -fsanitize=signed-integer-overflow -fsanitize=bounds -fsanitize=object-size -fsanitize=returns-nonnull-attribute -fsanitize=bool -fsanitize=enum -fsanitize=alignment -Wno-maybe-uninitialized -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(devfreq)" -D"KBUILD_MODNAME=KBUILD_STR(devfreq)" drivers/devfreq/devfreq.c
        59419 Segmentation fault      | scripts/genksyms/genksyms -r /dev/null > drivers/devfreq/.tmp_devfreq.ver

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

[-- Attachment #2: .config.gz --]
[-- Type: application/octet-stream, Size: 19570 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [PATCH 1/2] scripts: genksyms: fix resource leak
@ 2016-04-12 14:03 Maxim Zhukov
  2016-04-12 14:31 ` kbuild test robot
                   ` (2 more replies)
  0 siblings, 3 replies; 9+ messages in thread
From: Maxim Zhukov @ 2016-04-12 14:03 UTC (permalink / raw)
  To: Rob Herring; +Cc: Frank Rowand, Grant Likely, linux-kernel, Maxim Zhukov

This commit fixed resource leak at func main

Signed-off-by: Maxim Zhukov <mussitantesmortem@gmail.com>
---
 scripts/genksyms/genksyms.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/scripts/genksyms/genksyms.c b/scripts/genksyms/genksyms.c
index dafaf96..7c8f00e 100644
--- a/scripts/genksyms/genksyms.c
+++ b/scripts/genksyms/genksyms.c
@@ -873,5 +873,7 @@ int main(int argc, char **argv)
 			(double)nsyms / (double)HASH_BUCKETS);
 	}
 
+	fclose(dumpfile);
+
 	return errors != 0;
 }
-- 
2.7.1.1.g3617aa0

^ permalink raw reply related	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2016-04-12 15:40 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-04-12 15:18 [RESEND PATCH 0/2] scripts: small fixes Maxim Zhukov
2016-04-12 15:18 ` [PATCH 1/2] scripts: genksyms: fix resource leak Maxim Zhukov
2016-04-12 15:18 ` [PATCH 2/2] scripts: dtc: fix memory leak after realloc Maxim Zhukov
2016-04-12 15:39 ` [RESEND PATCH 0/2] scripts: small fixes Rob Herring
2016-04-12 15:40   ` Rob Herring
  -- strict thread matches above, loose matches on Subject: below --
2016-04-12 14:03 [PATCH 1/2] scripts: genksyms: fix resource leak Maxim Zhukov
2016-04-12 14:31 ` kbuild test robot
2016-04-12 14:39 ` kbuild test robot
2016-04-12 14:39 ` kbuild test robot

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.