public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Kees Cook <kees@kernel.org>
To: Masahiro Yamada <masahiroy@kernel.org>
Cc: kernel test robot <lkp@intel.com>,
	linux-hardening@vger.kernel.org, oe-kbuild-all@lists.linux.dev,
	linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 1/3] fortify: use if_changed_dep to record header dependency in *.cmd files
Date: Wed, 17 Jul 2024 15:19:05 -0700	[thread overview]
Message-ID: <202407171517.EC9EE07@keescook> (raw)
In-Reply-To: <CAK7LNARmJcyyzL-jVJfBPi3W684LTDmuhMf1koF0TXoCpKTmcw@mail.gmail.com>

On Wed, Jul 17, 2024 at 01:46:32PM +0900, Masahiro Yamada wrote:
> On Wed, Jul 17, 2024 at 2:51 AM kernel test robot <lkp@intel.com> wrote:
> >
> > Hi Masahiro,
> >
> > kernel test robot noticed the following build errors:
> >
> > [auto build test ERROR on linus/master]
> > [also build test ERROR on v6.10 next-20240716]
> > [cannot apply to akpm-mm/mm-nonmm-unstable kees/for-next/hardening kees/for-next/pstore kees/for-next/kspp]
> > [If your patch is applied to the wrong git tree, kindly drop us a note.
> > And when submitting patch, we suggest to use '--base' as documented in
> > https://git-scm.com/docs/git-format-patch#_base_tree_information]
> >
> > url:    https://github.com/intel-lab-lkp/linux/commits/Masahiro-Yamada/fortify-use-if_changed_dep-to-record-header-dependency-in-cmd-files/20240715-224820
> > base:   linus/master
> > patch link:    https://lore.kernel.org/r/20240715144529.101634-2-masahiroy%40kernel.org
> > patch subject: [PATCH 1/3] fortify: use if_changed_dep to record header dependency in *.cmd files
> > config: i386-randconfig-004-20240716 (https://download.01.org/0day-ci/archive/20240717/202407170104.dCe5MKsA-lkp@intel.com/config)
> > compiler: gcc-7 (Ubuntu 7.5.0-6ubuntu2) 7.5.0
> > reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240717/202407170104.dCe5MKsA-lkp@intel.com/reproduce)
> >
> > If you fix the issue in a separate patch/commit (i.e. not just a new version of
> > the same patch/commit), kindly add following tags
> > | Reported-by: kernel test robot <lkp@intel.com>
> > | Closes: https://lore.kernel.org/oe-kbuild-all/202407170104.dCe5MKsA-lkp@intel.com/
> >
> > All errors (new ones prefixed by >>):
> >
> > >> fixdep: error opening file: lib/test_fortify/.write_overflow-memcpy.log.d: No such file or directory
> > --
> > >> fixdep: error opening file: lib/test_fortify/.read_overflow2-memcmp.log.d: No such file or directory
> > --
> > >> fixdep: error opening file: lib/test_fortify/.read_overflow-memchr.log.d: No such file or directory
> > --
> > >> fixdep: error opening file: lib/test_fortify/.write_overflow-strcpy-lit.log.d: No such file or directory
> > --
> > >> fixdep: error opening file: lib/test_fortify/.read_overflow2-memmove.log.d: No such file or directory
> > --
> > >> fixdep: error opening file: lib/test_fortify/.write_overflow-strncpy-src.log.d: No such file or directory
> > --
> > >> fixdep: error opening file: lib/test_fortify/.read_overflow-memcmp.log.d: No such file or directory
> > --
> > >> fixdep: error opening file: lib/test_fortify/.read_overflow-memscan.log.d: No such file or directory
> > --
> > >> fixdep: error opening file: lib/test_fortify/.write_overflow-strcpy.log.d: No such file or directory
> > --
> > >> fixdep: error opening file: lib/test_fortify/.write_overflow-memmove.log.d: No such file or directory
> > --
> > >> fixdep: error opening file: lib/test_fortify/.write_overflow-memset.log.d: No such file or directory
> > ..
> 
> 
> 
> This issue seems to occur with GCC <=7
> 
> 
> $ echo 'void b(void) __attribute__((__error__(""))); void a(void) {
> b(); }' | gcc -Wp,-MMD,test.d -c -o /dev/null -x c -
> 
> 
> did not create *.d with GCC <= 7.
> 
> I do not see the issue with GCC >= 8 or Clang.

Any idea why this happens here and not for other sources in the tree?

> One quick solution is to skip the test for GCC <= 7.

I'd be fine with that -- it is designed to catch regressions/misbehaviours
in newly release compilers so I don't mind dropping checks against older
versions.

-- 
Kees Cook

  reply	other threads:[~2024-07-17 22:19 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-07-15 14:45 [PATCH 0/3] fortify: fix various issues in test_fortify Makefile Masahiro Yamada
2024-07-15 14:45 ` [PATCH 1/3] fortify: use if_changed_dep to record header dependency in *.cmd files Masahiro Yamada
2024-07-16 17:50   ` kernel test robot
2024-07-17  4:46     ` Masahiro Yamada
2024-07-17 22:19       ` Kees Cook [this message]
2024-07-18  4:22         ` Masahiro Yamada
2024-07-15 14:45 ` [PATCH 2/3] fortify: refactor test_fortify Makefile to fix some build problems Masahiro Yamada
2024-07-15 14:45 ` [PATCH 3/3] fortify: move test_fortify.sh to lib/test_fortify/ Masahiro Yamada
2024-07-15 16:07 ` [PATCH 0/3] fortify: fix various issues in test_fortify Makefile Kees Cook
2024-07-15 16:38   ` Masahiro Yamada

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=202407171517.EC9EE07@keescook \
    --to=kees@kernel.org \
    --cc=linux-hardening@vger.kernel.org \
    --cc=linux-kbuild@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lkp@intel.com \
    --cc=masahiroy@kernel.org \
    --cc=oe-kbuild-all@lists.linux.dev \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox