lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-ID: <201603201126.7ibw1CHI%fengguang.wu@intel.com>
Date:	Sun, 20 Mar 2016 11:07:33 +0800
From:	kbuild test robot <fengguang.wu@...el.com>
To:	Guenter Roeck <linux@...ck-us.net>
Cc:	kbuild-all@...org, linux-kernel@...r.kernel.org,
	Ralf Baechle <ralf@...ux-mips.org>
Subject: include/linux/workqueue.h:186:2: error: dereferencing type-punned
 pointer will break strict-aliasing rules

Hi Guenter,

FYI, the error/warning still remains.

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   1e75a9f34a5ed5902707fb74b468356c55142b71
commit: 398c7500a1f5f74e207bd2edca1b1721b3cc1f1e MIPS: VDSO: Fix build error with binutils 2.24 and earlier
date:   3 months ago
config: mips-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
        git checkout 398c7500a1f5f74e207bd2edca1b1721b3cc1f1e
        # save the attached .config to linux build tree
        make.cross ARCH=mips 

All errors (new ones prefixed by >>):

   In file included from include/linux/srcu.h:34:0,
                    from include/linux/notifier.h:15,
                    from arch/mips/include/asm/uprobes.h:9,
                    from include/linux/uprobes.h:61,
                    from include/linux/mm_types.h:13,
                    from arch/mips/include/asm/vdso.h:14,
                    from arch/mips/vdso/vdso.h:27,
                    from arch/mips/vdso/gettimeofday.c:11:
   include/linux/workqueue.h: In function 'work_static':
>> include/linux/workqueue.h:186:2: error: dereferencing type-punned pointer will break strict-aliasing rules [-Werror=strict-aliasing]
     return *work_data_bits(work) & WORK_STRUCT_STATIC;
     ^
   cc1: all warnings being treated as errors

vim +186 include/linux/workqueue.h

dd6414b5 Phil Carmody    2010-10-20  170  
65f27f38 David Howells   2006-11-22  171  #define DECLARE_WORK(n, f)						\
65f27f38 David Howells   2006-11-22  172  	struct work_struct n = __WORK_INITIALIZER(n, f)
65f27f38 David Howells   2006-11-22  173  
65f27f38 David Howells   2006-11-22  174  #define DECLARE_DELAYED_WORK(n, f)					\
f991b318 Tejun Heo       2012-08-21  175  	struct delayed_work n = __DELAYED_WORK_INITIALIZER(n, f, 0)
65f27f38 David Howells   2006-11-22  176  
203b42f7 Tejun Heo       2012-08-21  177  #define DECLARE_DEFERRABLE_WORK(n, f)					\
f991b318 Tejun Heo       2012-08-21  178  	struct delayed_work n = __DELAYED_WORK_INITIALIZER(n, f, TIMER_DEFERRABLE)
dd6414b5 Phil Carmody    2010-10-20  179  
dc186ad7 Thomas Gleixner 2009-11-16  180  #ifdef CONFIG_DEBUG_OBJECTS_WORK
dc186ad7 Thomas Gleixner 2009-11-16  181  extern void __init_work(struct work_struct *work, int onstack);
dc186ad7 Thomas Gleixner 2009-11-16  182  extern void destroy_work_on_stack(struct work_struct *work);
ea2e64f2 Thomas Gleixner 2014-03-23  183  extern void destroy_delayed_work_on_stack(struct delayed_work *work);
4690c4ab Tejun Heo       2010-06-29  184  static inline unsigned int work_static(struct work_struct *work)
4690c4ab Tejun Heo       2010-06-29  185  {
22df02bb Tejun Heo       2010-06-29 @186  	return *work_data_bits(work) & WORK_STRUCT_STATIC;
4690c4ab Tejun Heo       2010-06-29  187  }
dc186ad7 Thomas Gleixner 2009-11-16  188  #else
dc186ad7 Thomas Gleixner 2009-11-16  189  static inline void __init_work(struct work_struct *work, int onstack) { }
dc186ad7 Thomas Gleixner 2009-11-16  190  static inline void destroy_work_on_stack(struct work_struct *work) { }
ea2e64f2 Thomas Gleixner 2014-03-23  191  static inline void destroy_delayed_work_on_stack(struct delayed_work *work) { }
4690c4ab Tejun Heo       2010-06-29  192  static inline unsigned int work_static(struct work_struct *work) { return 0; }
dc186ad7 Thomas Gleixner 2009-11-16  193  #endif
dc186ad7 Thomas Gleixner 2009-11-16  194  

:::::: The code at line 186 was first introduced by commit
:::::: 22df02bb3fab24af97bff4c69cc6fd8529fc66fe workqueue: define masks for work flags and conditionalize STATIC flags

:::::: TO: Tejun Heo <tj@...nel.org>
:::::: CC: Tejun Heo <tj@...nel.org>

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

Download attachment ".config.gz" of type "application/octet-stream" (39739 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ