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>] [<thread-prev] [day] [month] [year] [list]
Date:   Wed, 26 Jul 2017 12:47:07 +0200
From:   Daniel Vetter <daniel@...ll.ch>
To:     Arnd Bergmann <arnd@...db.de>
Cc:     Daniel Vetter <daniel.vetter@...ll.ch>,
        Xinliang Liu <z.liuxinliang@...ilicon.com>,
        Rongrong Zou <zourongrong@...il.com>,
        Xinwei Kong <kong.kongxinwei@...ilicon.com>,
        Chen Feng <puck.chen@...ilicon.com>,
        David Airlie <airlied@...ux.ie>,
        Sean Paul <seanpaul@...omium.org>,
        Russell King <rmk+kernel@...linux.org.uk>,
        Gabriel Krisman Bertazi <krisman@...labora.co.uk>,
        Jani Nikula <jani.nikula@...el.com>,
        Thierry Reding <treding@...dia.com>,
        Rob Herring <robh@...nel.org>, Shawn Guo <shawnguo@...nel.org>,
        dri-devel <dri-devel@...ts.freedesktop.org>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v2] drm/hisilicon: fix build error without fbdev emulation

On Wed, Jul 26, 2017 at 08:58:16AM +0200, Arnd Bergmann wrote:
> On Wed, Jul 26, 2017 at 7:55 AM, Daniel Vetter <daniel.vetter@...ll.ch> wrote:
> > On Tue, Jul 25, 2017 at 8:05 PM, Arnd Bergmann <arnd@...db.de> wrote:
> >> We cannot reference priv->fbdev outside of the #ifdef:
> >>
> >> drivers/net/virtio_net.c:1881:12: error: 'virtnet_restore_up' defined but not used [-Werror=unused-function]
> >>  static int virtnet_restore_up(struct virtio_device *vdev)
> >> drivers/net/virtio_net.c:1859:13: error: 'virtnet_freeze_down' defined but not used [-Werror=unused-function]
> >>  static void virtnet_freeze_down(struct virtio_device *vdev)
> >>
> >> As the #ifdef is a bit annoying here, this removes it entirely
> >> and uses an IS_ENABLED() check in it place where needed.
> >>
> >> Fixes: b4dd9f1ffaba ("drm/hisilicon: Remove custom FB helper deferred setup")
> >> Signed-off-by: Arnd Bergmann <arnd@...db.de>
> >
> > I guess I wasn't clear enough, but you don't even need the IS_ENABLED.
> > The cma_fini/init functions themselves don't get no-opped out (I guess
> > we could fix that), but the underlying fb helper functions they call
> > do, so this is all perfectly fine to call unconditionally. And that's
> > what all other drivers do. Should I edit while applying, or do you
> > want to respin?
> 
> Please just edit as you like then, I think that's quicker.
> 
> The version I sent was meant to have smaller object code as well, and
> I didn't think we could rely on drm_fb_cma_helper.c being built without
> CONFIG_DRM_FBDEV_EMULATION, but I see now that they are
> independent as you say, so making them unconditional indeed gives
> the simplest code.

Done, thanks.
-Daniel
-- 
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ