mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: YE Chengfeng <cyeaa@connect.ust.hk>
To: Zhou Wang <wangzhou1@hisilicon.com>,
	"herbert@gondor.apana.org.au" <herbert@gondor.apana.org.au>,
	"davem@davemloft.net" <davem@davemloft.net>
Cc: "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: 回复: drivers/crypto: suspected missing null check in hisi_qm_pre_init
Date: Thu, 28 Oct 2021 02:20:33 +0000	[thread overview]
Message-ID: <TYCP286MB11880901F8D4A1563F0DF34F8A869@TYCP286MB1188.JPNP286.PROD.OUTLOOK.COM> (raw)
In-Reply-To: <e1d5b35e-5055-34de-5864-f2331c9ac051@hisilicon.com>

Got it.
Thanks for your reply.

Best regards,
Chengfeng

-----邮件原件-----
发件人: Zhou Wang <wangzhou1@hisilicon.com> 
发送时间: 2021年10月28日 9:24
收件人: YE Chengfeng <cyeaa@connect.ust.hk>; herbert@gondor.apana.org.au; davem@davemloft.net
抄送: linux-kernel@vger.kernel.org
主题: Re: drivers/crypto: suspected missing null check in hisi_qm_pre_init

> Hi,
> 
> https://apc01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgith
> ub.com%2Ftorvalds%2Flinux%2Fblob%2Fmaster%2Fdrivers%2Fcrypto%2Fhisilic
> on%2Fqm.c%23L3286&amp;data=04%7C01%7Ccyeaa%40connect.ust.hk%7C98c99b9b
> 25084a3fac8d08d999b1a9cb%7C6c1d415239d044ca88d9b8d6ddca0708%7C1%7C0%7C
> 637709810602673947%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjo
> iV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&amp;sdata=e3p0PP1tp%2BA
> %2BrUALUgrowuYEZT3L21WoQBqfAn5iKac%3D&amp;reserved=0
> 
> We notice that at #line 3286, the return pointer of ACPI_COMPANION is not null-checked, and then it's dereferenced in acpi_device_power_manageable. Seems that it could be a potential null-pointer-dereference issue.
> 
> This is detected by our experimental static analysis tool, it could be false positive, so we manually check and report those we think may be true bugs. Would you like to have a look at them? If it's real bug, we could like to provide patch to ease your workflow.

Hi Chengfeng,

It will reture NULL when ACPI is disabled, however this driver deponds on ACPI, which is already set in Kconfig. So no need do null-checked here.

Thanks,
Zhou

> 
> Thanks so much,
> Chengfeng
> .
> 

      reply	other threads:[~2021-10-28  2:20 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-27 11:06 YE Chengfeng
2021-10-28  1:24 ` Zhou Wang
2021-10-28  2:20   ` YE Chengfeng [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=TYCP286MB11880901F8D4A1563F0DF34F8A869@TYCP286MB1188.JPNP286.PROD.OUTLOOK.COM \
    --to=cyeaa@connect.ust.hk \
    --cc=davem@davemloft.net \
    --cc=herbert@gondor.apana.org.au \
    --cc=linux-kernel@vger.kernel.org \
    --cc=wangzhou1@hisilicon.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®