lkml.org 
[lkml]   [2018]   [Nov]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [PATCH 06/15] Bluetooth: hci_bcm: Simplify clk_get error handling
    On Wed, Nov 07, 2018 at 06:12:59PM +0800, Chen-Yu Tsai wrote:
    > @@ -911,6 +911,10 @@ static int bcm_get_resources(struct bcm_device *dev)
    > if (IS_ERR(dev->clk) && PTR_ERR(dev->clk) == -EPROBE_DEFER)

    You can also simplify the above test to:

    if (dev->clk == ERR_PTR(-EPROBE_DEFER))

    as error pointers are uniquely different from normal pointers.

    --
    RMK's Patch system: http://www.armlinux.org.uk/developer/patches/
    FTTC broadband for 0.8mile line in suburbia: sync at 12.1Mbps down 622kbps up
    According to speedtest.net: 11.9Mbps down 500kbps up

    \
     
     \ /
      Last update: 2018-11-07 11:52    [W:4.588 / U:0.020 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site