Thread (3 messages) 3 messages, 3 authors, 2021-09-01

Re: drivers/crypto/qat/qat_c62xvf/adf_c62xvf_hw_data.c:102:28: warning: taking address of packed member 'csr_ops' of class or structure 'adf_hw_device_data' may result in an unaligned pointer value

flat view

From: Giovanni Cabiddu <giovanni.cabiddu@intel.com>
Date: 2021-09-01 11:36:46
Also in: lkml, oe-kbuild-all

On Wed, Sep 01, 2021 at 02:18:17PM +0300, Andy Shevchenko wrote:
On Wed, Sep 01, 2021 at 12:19:08AM +0800, kernel test robot wrote:
quoted
quoted
quoted
drivers/crypto/qat/qat_c62xvf/adf_c62xvf_hw_data.c:102:28: warning: taking address of packed member 'csr_ops' of class or structure 'adf_hw_device_data' may result in an unaligned pointer value [-Waddress-of-packed-member]
           adf_gen2_init_hw_csr_ops(&hw_data->csr_ops);
                                     ^~~~~~~~~~~~~~~~
   3 warnings generated.

Why on Earth the struct adf_hw_device_data, that contains a lot of pointers,
marked as __packed?! That __packed has to be dropped.
That struct doesn't need to be marked as __packed.
I'm going to send a patch that drops that attribute for all the
structures that do not need to be packed in the QAT driver.

-- 
Giovanni
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help