[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAGXu5jL8qzxGq49vBBH9f1+GgCtVUA8MK=ed-qmWMaq=TetPDg@mail.gmail.com>
Date: Thu, 26 Sep 2013 15:36:09 -0500
From: Kees Cook <keescook@...omium.org>
To: Ingo Molnar <mingo@...nel.org>
Cc: LKML <linux-kernel@...r.kernel.org>,
"H. Peter Anvin" <hpa@...or.com>,
Thomas Gleixner <tglx@...utronix.de>,
Ingo Molnar <mingo@...hat.com>,
"x86@...nel.org" <x86@...nel.org>, Jiri Slaby <jslaby@...e.cz>,
David Woodhouse <David.Woodhouse@...el.com>
Subject: Re: [PATCH] x86, build: move build output statistics away from stderr
On Mon, Sep 9, 2013 at 3:49 AM, Ingo Molnar <mingo@...nel.org> wrote:
>
> * Kees Cook <keescook@...omium.org> wrote:
>
>> When building on x86, the final image building step always emits stats
>> to stderr, even though this information is neither a warning nor an error:
>>
>> BUILD arch/x86/boot/bzImage
>> Setup is 16188 bytes (padded to 16384 bytes).
>> System is 6368 kB
>> CRC cbe50c61
>>
>> Validating automated builds would be cleaner if stderr did not have to
>> filter out these lines. Instead, change how tools/build is called, and
>> make the zoffset header unconditional, and write to a specified file
>> instead of to stdout, which can then be used for statistics, leaving
>> stderr open for legitimate warnings and errors, like the output from
>> die().
>
> Nice, that output to stderr was always somewhat annoying.
>
>> + /* Catch any delayed write failures */
>> + if (fclose(dest))
>> + die("Writing image failed");
>> +
>> close(fd);
>
> Looks like the new code is not just reporting errors better, but it's more
> robust by catching and reporting fclose()-time failures as well, avoiding
> a corrupt kernel image in certain corner cases - the most common being a
> file system full error I suspect.
Quick ping on this; can someone pick it up in their tree?
Thanks!
-Kees
>
> Thanks,
>
> Ingo
--
Kees Cook
Chrome OS Security
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists