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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <37256c8abfaf2cfaa53a677eccd7edecdc5a5dd8.camel@mediatek.com>
Date:   Tue, 18 Jul 2023 09:19:06 +0000
From:   CK Hu (胡俊光) <ck.hu@...iatek.com>
To:     "angelogioacchino.delregno@...labora.com" 
        <angelogioacchino.delregno@...labora.com>,
        "chunkuang.hu@...nel.org" <chunkuang.hu@...nel.org>
CC:     "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "linux-mediatek@...ts.infradead.org" 
        <linux-mediatek@...ts.infradead.org>,
        "wenst@...omium.org" <wenst@...omium.org>,
        "kernel@...labora.com" <kernel@...labora.com>,
        "dri-devel@...ts.freedesktop.org" <dri-devel@...ts.freedesktop.org>,
        "linux-arm-kernel@...ts.infradead.org" 
        <linux-arm-kernel@...ts.infradead.org>,
        "matthias.bgg@...il.com" <matthias.bgg@...il.com>,
        "nfraprado@...labora.com" <nfraprado@...labora.com>
Subject: Re: [PATCH v6 03/11] drm/mediatek: dp: Change logging to dev for
 mtk_dp_aux_transfer()

Hi, Angelo:

On Mon, 2023-07-17 at 16:14 +0200, AngeloGioacchino Del Regno wrote:
>  	 
> External email : Please do not click links or open attachments until
> you have verified the sender or the content.
>  Change logging from drm_{err,info}() to dev_{err,info}() in
> functions
> mtk_dp_aux_transfer() and mtk_dp_aux_do_transfer(): this will be
> essential to avoid getting NULL pointer kernel panics if any kind
> of error happens during AUX transfers happening before the bridge
> is attached.
> 
> This may potentially start happening in a later commit implementing
> aux-bus support, as AUX transfers will be triggered from the panel
> driver (for EDID) before the mtk-dp bridge gets attached, and it's
> done in preparation for the same.

Reviewed-by: CK Hu <ck.hu@...iatek.com>

> 
> Signed-off-by: AngeloGioacchino Del Regno <
> angelogioacchino.delregno@...labora.com>
> Tested-by: Chen-Yu Tsai <wenst@...omium.org>
> ---
>  drivers/gpu/drm/mediatek/mtk_dp.c | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/gpu/drm/mediatek/mtk_dp.c
> b/drivers/gpu/drm/mediatek/mtk_dp.c
> index 77da0d002e9f..98f63d8230e4 100644
> --- a/drivers/gpu/drm/mediatek/mtk_dp.c
> +++ b/drivers/gpu/drm/mediatek/mtk_dp.c
> @@ -847,7 +847,7 @@ static int mtk_dp_aux_do_transfer(struct mtk_dp
> *mtk_dp, bool is_read, u8 cmd,
>  		u32 phy_status = mtk_dp_read(mtk_dp,
> MTK_DP_AUX_P0_3628) &
>  				 AUX_RX_PHY_STATE_AUX_TX_P0_MASK;
>  		if (phy_status != AUX_RX_PHY_STATE_AUX_TX_P0_RX_IDLE) {
> -			drm_err(mtk_dp->drm_dev,
> +			dev_err(mtk_dp->dev,
>  				"AUX Rx Aux hang, need SW reset\n");
>  			return -EIO;
>  		}
> @@ -2054,7 +2054,7 @@ static ssize_t mtk_dp_aux_transfer(struct
> drm_dp_aux *mtk_aux,
>  		is_read = true;
>  		break;
>  	default:
> -		drm_err(mtk_aux->drm_dev, "invalid aux cmd = %d\n",
> +		dev_err(mtk_dp->dev, "invalid aux cmd = %d\n",
>  			msg->request);
>  		ret = -EINVAL;
>  		goto err;
> @@ -2070,7 +2070,7 @@ static ssize_t mtk_dp_aux_transfer(struct
> drm_dp_aux *mtk_aux,
>  					     to_access, &msg->reply);
>  
>  		if (ret) {
> -			drm_info(mtk_dp->drm_dev,
> +			dev_info(mtk_dp->dev,
>  				 "Failed to do AUX transfer: %d\n",
> ret);
>  			goto err;
>  		}
> -- 
> 2.40.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ