From mboxrd@z Thu Jan 1 00:00:00 1970 From: Greg Kroah-Hartman Subject: Re: [-next] FATAL: drivers/gpu/drm/udl/udl: sizeof(struct usb_device_id)=24 is not a modulo of the size of section __mod_usb_device_table=44. Date: Fri, 15 Jun 2012 13:10:21 -0700 Message-ID: <20120615201021.GB14544@kroah.com> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from mail-pb0-f46.google.com ([209.85.160.46]:35619 "EHLO mail-pb0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1757228Ab2FOUK0 (ORCPT ); Fri, 15 Jun 2012 16:10:26 -0400 Received: by pbbrp8 with SMTP id rp8so5713097pbb.19 for ; Fri, 15 Jun 2012 13:10:26 -0700 (PDT) Content-Disposition: inline In-Reply-To: Sender: linux-next-owner@vger.kernel.org List-ID: To: Geert Uytterhoeven Cc: =?iso-8859-1?Q?Bj=F8rn?= Mork , USB list , linux-kernel@vger.kernel.org, Linux-Next , linux-kbuild , Linux/m68k On Fri, Jun 15, 2012 at 07:42:08PM +0200, Geert Uytterhoeven wrote: > commit 81df2d594340dcb6d1a02191976be88a1ca8120c ("USB: allow match > on bInterfaceNumber") added a byte to the interior of struct usb_device_id, > enabling implicit padding: > > --- a/include/linux/mod_devicetable.h > +++ b/include/linux/mod_devicetable.h > @@ -115,6 +118,9 @@ struct usb_device_id { > __u8 bInterfaceSubClass; > __u8 bInterfaceProtocol; > > + /* Used for vendor-specific interface matches */ > + __u8 bInterfaceNumber; > + > /* not matched against */ > kernel_ulong_t driver_info; > }; > > On m68k, this causes failures like: > > | FATAL: drivers/gpu/drm/udl/udl: sizeof(struct usb_device_id)=24 is > not a modulo of the size of section __mod_usb_device_table=44. > | Fix definition of struct usb_device_id in mod_devicetable.h > > M68k is special in that it uses 2 for the alignment of 32-bit entities, hence > sizeof(struct usb_device_id) = 22. > > However, when cross-compiling on amd64, sizeof(struct usb_device_id) = 24 > in scripts/mod/file2alias.c. I don't really understand, what is the problem here? The fact that we added one byte to the structure? And now something breaks? How? What can we do to resolve it? confused, greg k-h