From 16f890988114a1b2d7abb30dafb708d4513801da Mon Sep 17 00:00:00 2001 From: Charles Keepax Date: Mon, 15 Oct 2012 13:49:12 +0100 Subject: kbuild: Remove reference to uninitialised variable Verbose output variable is unnecessary because the command's echo is already surpressed. Additionally because the block defines skip-makefile the variable Q is not defined within the makefile, which can cause problems if Q is defined in the users environment. Signed-off-by: Charles Keepax Signed-off-by: Michal Marek --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 5be2ee8c90e4..6744909b345f 100644 --- a/Makefile +++ b/Makefile @@ -124,7 +124,7 @@ $(if $(KBUILD_OUTPUT),, \ PHONY += $(MAKECMDGOALS) sub-make $(filter-out _all sub-make $(CURDIR)/Makefile, $(MAKECMDGOALS)) _all: sub-make - $(Q)@: + @: sub-make: FORCE $(if $(KBUILD_VERBOSE:1=),@)$(MAKE) -C $(KBUILD_OUTPUT) \ -- cgit v1.2.3 From fc96b211bc6fa917bfb07a8db4cd898663e5f2c6 Mon Sep 17 00:00:00 2001 From: Andreas Bießmann Date: Thu, 18 Oct 2012 11:08:49 +0200 Subject: scripts/pnmtologo: fix for plain PBM MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit PBM generated with current tools do not have a whitespace between the digits. Therefore the pnmtologo tool fails to gernerate the required C-Array for these images. This patch fixes that behaviour and can handle both 'old style' and 'new style' PBM files. Signed-off-by: Andreas Bießmann Signed-off-by: Michal Marek --- scripts/pnmtologo.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/scripts/pnmtologo.c b/scripts/pnmtologo.c index 5c113123ed9f..68bb4efc5af4 100644 --- a/scripts/pnmtologo.c +++ b/scripts/pnmtologo.c @@ -74,6 +74,7 @@ static unsigned int logo_height; static struct color **logo_data; static struct color logo_clut[MAX_LINUX_LOGO_COLORS]; static unsigned int logo_clutsize; +static int is_plain_pbm = 0; static void die(const char *fmt, ...) __attribute__ ((noreturn)) __attribute ((format (printf, 1, 2))); @@ -103,6 +104,11 @@ static unsigned int get_number(FILE *fp) val = 0; while (isdigit(c)) { val = 10*val+c-'0'; + /* some PBM are 'broken'; GiMP for example exports a PBM without space + * between the digits. This is Ok cause we know a PBM can only have a '1' + * or a '0' for the digit. */ + if (is_plain_pbm) + break; c = fgetc(fp); if (c == EOF) die("%s: end of file\n", filename); @@ -167,6 +173,7 @@ static void read_image(void) switch (magic) { case '1': /* Plain PBM */ + is_plain_pbm = 1; for (i = 0; i < logo_height; i++) for (j = 0; j < logo_width; j++) logo_data[i][j].red = logo_data[i][j].green = -- cgit v1.2.3 From bd1ee804af8bdf2fd5131234330615f8aecbd9ed Mon Sep 17 00:00:00 2001 From: Pawel Moll Date: Mon, 29 Oct 2012 11:23:02 +0000 Subject: kbuild: Do not remove vmlinux when cleaning external module Since commit 1f2bfbd00e466ff3489b2ca5cc75b1cccd14c123 "kbuild: link of vmlinux moved to a script" make clean with M= argument (so cleaning external module) removes vmlinux, System.map and couple of other files from the *main* kernel build directory! This not what was happening before and almost certainly not what one would expect. This patch moves makes the clean target of the script called only when !KBUILD_EXTMOD. Signed-off-by: Pawel Moll Cc: stable@vger.kernel.org [v3.5+] Signed-off-by: Michal Marek --- Makefile | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 6744909b345f..4781b534873b 100644 --- a/Makefile +++ b/Makefile @@ -1008,11 +1008,14 @@ clean: rm-dirs := $(CLEAN_DIRS) clean: rm-files := $(CLEAN_FILES) clean-dirs := $(addprefix _clean_, . $(vmlinux-alldirs) Documentation samples) -PHONY += $(clean-dirs) clean archclean +PHONY += $(clean-dirs) clean archclean vmlinuxclean $(clean-dirs): $(Q)$(MAKE) $(clean)=$(patsubst _clean_%,%,$@) -clean: archclean +vmlinuxclean: + $(Q)$(CONFIG_SHELL) $(srctree)/scripts/link-vmlinux.sh clean + +clean: archclean vmlinuxclean # mrproper - Delete all generated files, including .config # @@ -1239,7 +1242,6 @@ scripts: ; endif # KBUILD_EXTMOD clean: $(clean-dirs) - $(Q)$(CONFIG_SHELL) $(srctree)/scripts/link-vmlinux.sh clean $(call cmd,rmdirs) $(call cmd,rmfiles) @find $(if $(KBUILD_EXTMOD), $(KBUILD_EXTMOD), .) $(RCS_FIND_IGNORE) \ -- cgit v1.2.3