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] [thread-next>] [day] [month] [year] [list]
Message-ID: <5c4c994b-8868-f68c-cd0d-7f7a2530f697@nxp.com>
Date:   Thu, 30 Apr 2020 17:23:46 +0300
From:   Daniel Baluta <daniel.baluta@....com>
To:     Schrempf Frieder <frieder.schrempf@...tron.de>,
        Adam Ford <aford173@...il.com>,
        Anson Huang <Anson.Huang@....com>,
        Christian Gmeiner <christian.gmeiner@...il.com>,
        Fabio Estevam <festevam@...il.com>,
        Leonard Crestez <leonard.crestez@....com>,
        Li Jun <jun.li@....com>, Lucas Stach <l.stach@...gutronix.de>,
        NXP Linux Team <linux-imx@....com>,
        Peng Fan <peng.fan@....com>,
        Pengutronix Kernel Team <kernel@...gutronix.de>,
        Russell King <linux+etnaviv@...linux.org.uk>,
        Sascha Hauer <s.hauer@...gutronix.de>,
        Shawn Guo <shawnguo@...nel.org>,
        "S.j. Wang" <shengjiu.wang@....com>
Cc:     "devicetree@...r.kernel.org" <devicetree@...r.kernel.org>,
        "dri-devel@...ts.freedesktop.org" <dri-devel@...ts.freedesktop.org>,
        "etnaviv@...ts.freedesktop.org" <etnaviv@...ts.freedesktop.org>,
        "linux-arm-kernel@...ts.infradead.org" 
        <linux-arm-kernel@...ts.infradead.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [RFC PATCH 1/4] drm/etnaviv: Prevent IRQ triggering at probe time
 on i.MX8MM

On 4/30/20 3:46 PM, Schrempf Frieder wrote:
>   
> +	/*
> +	 * On i.MX8MM there is an interrupt getting triggered immediately
> +	 * after requesting the IRQ, which leads to a stall as the handler
> +	 * accesses the GPU registers whithout the clock being enabled.
> +	 * Enabling the clocks briefly seems to clear the IRQ state, so we do
> +	 * this here before requesting the IRQ.
> +	 */
> +	err = etnaviv_gpu_clk_enable(gpu);
> +	if (err)
> +		return err;
> +
> +	err = etnaviv_gpu_clk_disable(gpu);
> +	if (err)
> +		return err;
> +
> +	err = devm_request_irq(&pdev->dev, gpu->irq, irq_handler, 0,
> +			       dev_name(gpu->dev), gpu);
> +	if (err) {
> +		dev_err(dev, "failed to request IRQ%u: %d\n", gpu->irq, err);
> +		return err;
> +	}

Shouldn't you disable the clk after devm_request_irq is called?


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ