All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andy Shevchenko <andy.shevchenko@gmail.com>
To: kernel test robot <lkp@intel.com>
Cc: Sakari Ailus <sakari.ailus@linux.intel.com>,
	llvm@lists.linux.dev,  kbuild-all@lists.01.org,
	 Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Thomas Zimmermann <tzimmermann@suse.de>,
	 Petr Mladek <pmladek@suse.com>,
	Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Subject: Re: drivers/media/v4l2-core/v4l2-ioctl.c:303:28: warning: taking address of packed member 'pixelformat' of class or structure 'v4l2_pix_format_mplane' may result in an unaligned pointer value
Date: Fri, 5 Nov 2021 12:21:48 +0200	[thread overview]
Message-ID: <CAHp75Ve=ByJ+KMFXsH6sYQeM+FAzgYBX80TqdVfb5_YFLX3sdw@mail.gmail.com> (raw)
In-Reply-To: <202111050644.9HQjbpIQ-lkp@intel.com>

On Fri, Nov 5, 2021 at 12:24 AM kernel test robot <lkp@intel.com> wrote:
>
> tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
> head:   c1e2e0350ce37f633b5ce3ce1cdf4428513fc2a2
> commit: e927e1e0f0dd3e353d5556503a71484008692c82 v4l: ioctl: Use %p4cc printk modifier to print FourCC codes
> date:   9 months ago
> config: mips-randconfig-r011-20211101 (attached as .config)
> compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project 82ed106567063ea269c6d5669278b733e173a42f)
> reproduce (this is a W=1 build):
>         wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
>         chmod +x ~/bin/make.cross
>         # install mips cross compiling tool for clang build
>         # apt-get install binutils-mips-linux-gnu
>         # https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=e927e1e0f0dd3e353d5556503a71484008692c82
>         git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
>         git fetch --no-tags linus master
>         git checkout e927e1e0f0dd3e353d5556503a71484008692c82
>         # save the attached .config to linux build tree
>         COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 ARCH=mips
>
> If you fix the issue, kindly add following tag as appropriate
> Reported-by: kernel test robot <lkp@intel.com>
>
> All warnings (new ones prefixed by >>):
>
> >> drivers/media/v4l2-core/v4l2-ioctl.c:303:28: warning: taking address of packed member 'pixelformat' of class or structure 'v4l2_pix_format_mplane' may result in an unaligned pointer value [-Waddress-of-packed-member]

Yeah, I discussed it with Sakari a few months ago. Dunno what is the outcome.
TL;DR: some are easy to fix, i.e. by dropping __packed, the rest needs
more thinking...


-- 
With Best Regards,
Andy Shevchenko

WARNING: multiple messages have this Message-ID (diff)
From: Andy Shevchenko <andy.shevchenko@gmail.com>
To: kbuild-all@lists.01.org
Subject: Re: drivers/media/v4l2-core/v4l2-ioctl.c:303:28: warning: taking address of packed member 'pixelformat' of class or structure 'v4l2_pix_format_mplane' may result in an unaligned pointer value
Date: Fri, 05 Nov 2021 12:21:48 +0200	[thread overview]
Message-ID: <CAHp75Ve=ByJ+KMFXsH6sYQeM+FAzgYBX80TqdVfb5_YFLX3sdw@mail.gmail.com> (raw)
In-Reply-To: <202111050644.9HQjbpIQ-lkp@intel.com>

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

On Fri, Nov 5, 2021 at 12:24 AM kernel test robot <lkp@intel.com> wrote:
>
> tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
> head:   c1e2e0350ce37f633b5ce3ce1cdf4428513fc2a2
> commit: e927e1e0f0dd3e353d5556503a71484008692c82 v4l: ioctl: Use %p4cc printk modifier to print FourCC codes
> date:   9 months ago
> config: mips-randconfig-r011-20211101 (attached as .config)
> compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project 82ed106567063ea269c6d5669278b733e173a42f)
> reproduce (this is a W=1 build):
>         wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
>         chmod +x ~/bin/make.cross
>         # install mips cross compiling tool for clang build
>         # apt-get install binutils-mips-linux-gnu
>         # https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=e927e1e0f0dd3e353d5556503a71484008692c82
>         git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
>         git fetch --no-tags linus master
>         git checkout e927e1e0f0dd3e353d5556503a71484008692c82
>         # save the attached .config to linux build tree
>         COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 ARCH=mips
>
> If you fix the issue, kindly add following tag as appropriate
> Reported-by: kernel test robot <lkp@intel.com>
>
> All warnings (new ones prefixed by >>):
>
> >> drivers/media/v4l2-core/v4l2-ioctl.c:303:28: warning: taking address of packed member 'pixelformat' of class or structure 'v4l2_pix_format_mplane' may result in an unaligned pointer value [-Waddress-of-packed-member]

Yeah, I discussed it with Sakari a few months ago. Dunno what is the outcome.
TL;DR: some are easy to fix, i.e. by dropping __packed, the rest needs
more thinking...


-- 
With Best Regards,
Andy Shevchenko

  reply	other threads:[~2021-11-05 10:22 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-11-04 22:21 drivers/media/v4l2-core/v4l2-ioctl.c:303:28: warning: taking address of packed member 'pixelformat' of class or structure 'v4l2_pix_format_mplane' may result in an unaligned pointer value kernel test robot
2021-11-04 22:21 ` kernel test robot
2021-11-05 10:21 ` Andy Shevchenko [this message]
2021-11-05 10:21   ` Andy Shevchenko
  -- strict thread matches above, loose matches on Subject: below --
2022-01-17  3:40 kernel test robot
2022-01-17  3:40 ` kernel test robot
2022-01-08 10:33 kernel test robot
2022-01-08 10:33 ` kernel test robot
2022-01-09 14:26 ` Andy Shevchenko
2022-01-09 14:26   ` Andy Shevchenko
2022-01-10 19:44   ` Nick Desaulniers
2022-01-10 19:44     ` Nick Desaulniers
2022-01-10 20:49     ` Andy Shevchenko
2022-01-10 20:49       ` Andy Shevchenko
2022-01-10 21:22       ` Nick Desaulniers
2022-01-10 21:22         ` Nick Desaulniers
2021-07-14 17:55 kernel test robot
2021-07-14 17:55 ` kernel test robot
2021-07-14 19:45 ` Andy Shevchenko
2021-07-14 19:45   ` Andy Shevchenko
2021-07-16 11:41   ` Sakari Ailus
2021-07-16 11:41     ` Sakari Ailus
2021-07-16 12:12     ` Andy Shevchenko
2021-07-16 12:12       ` Andy Shevchenko
2021-08-19  8:10       ` Sakari Ailus
2021-08-19  8:10         ` Sakari Ailus
2021-08-26 13:22         ` Petr Mladek
2021-08-26 13:22           ` Petr Mladek

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='CAHp75Ve=ByJ+KMFXsH6sYQeM+FAzgYBX80TqdVfb5_YFLX3sdw@mail.gmail.com' \
    --to=andy.shevchenko@gmail.com \
    --cc=andriy.shevchenko@linux.intel.com \
    --cc=kbuild-all@lists.01.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lkp@intel.com \
    --cc=llvm@lists.linux.dev \
    --cc=pmladek@suse.com \
    --cc=sakari.ailus@linux.intel.com \
    --cc=tzimmermann@suse.de \
    /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 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.