From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: Tong Zhang <ztong0001@gmail.com>
Cc: Felipe Balbi <balbi@kernel.org>, Lee Jones <lee.jones@linaro.org>,
"Alexander A. Klimov" <grandmaster@al2klimov.de>,
linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] usb: gadget: udc: amd5536udc_pci fix crash if dma is used
Date: Wed, 17 Mar 2021 21:43:36 +0100 [thread overview]
Message-ID: <YFJp+It0/f7O9YId@kroah.com> (raw)
In-Reply-To: <20210313192033.2611349-1-ztong0001@gmail.com>
On Sat, Mar 13, 2021 at 02:20:32PM -0500, Tong Zhang wrote:
> init_dma_pools() calls dma_pool_create(...dev->dev) to create dma pool.
> however, dev->dev is actually set after calling init_dma_pools(), which
> effectively makes dma_pool_create(..NULL) and cause crash.
> To fix this issue, init dma only after dev->dev is set.
>
> [ 1.317993] RIP: 0010:dma_pool_create+0x83/0x290
> [ 1.323257] Call Trace:
> [ 1.323390] ? pci_write_config_word+0x27/0x30
> [ 1.323626] init_dma_pools+0x41/0x1a0 [snps_udc_core]
> [ 1.323899] udc_pci_probe+0x202/0x2b1 [amd5536udc_pci]
>
> Signed-off-by: Tong Zhang <ztong0001@gmail.com>
What commit caused this problem?
Can you resend this with a "Fixes:" tag added showing that?
thanks,
greg k-h
next prev parent reply other threads:[~2021-03-17 20:44 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-03-13 19:20 [PATCH] usb: gadget: udc: amd5536udc_pci fix crash if dma is used Tong Zhang
2021-03-17 20:43 ` Greg Kroah-Hartman [this message]
2021-03-17 23:04 ` [PATCH v2] usb: gadget: udc: amd5536udc_pci fix null-ptr-dereference Tong Zhang
2021-03-17 23:10 ` [PATCH] usb: gadget: udc: amd5536udc_pci fix crash if dma is used Tong Zhang
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=YFJp+It0/f7O9YId@kroah.com \
--to=gregkh@linuxfoundation.org \
--cc=balbi@kernel.org \
--cc=grandmaster@al2klimov.de \
--cc=lee.jones@linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--cc=ztong0001@gmail.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.