From: Can Guo <cang@codeaurora.org>
To: Bart Van Assche <bvanassche@acm.org>
Cc: asutoshd@codeaurora.org, nguyenb@codeaurora.org,
hongwus@codeaurora.org, rnayak@codeaurora.org,
linux-scsi@vger.kernel.org, kernel-team@android.com,
saravanak@google.com, salyzyn@google.com,
Andy Gross <agross@kernel.org>,
Bjorn Andersson <bjorn.andersson@linaro.org>,
Alim Akhtar <alim.akhtar@samsung.com>,
Avri Altman <avri.altman@wdc.com>,
"James E.J. Bottomley" <jejb@linux.ibm.com>,
"Martin K. Petersen" <martin.petersen@oracle.com>,
Stanley Chu <stanley.chu@mediatek.com>,
Bean Huo <beanhuo@micron.com>,
Venkat Gopalakrishnan <venkatg@codeaurora.org>,
Tomas Winkler <tomas.winkler@intel.com>,
"open list:ARM/QUALCOMM SUPPORT" <linux-arm-msm@vger.kernel.org>,
open list <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] scsi: ufs: Fix registers dump vops caused scheduling while atomic
Date: Wed, 05 Feb 2020 14:31:45 +0800 [thread overview]
Message-ID: <749a1db94df00278ec9f5c121cd937fe@codeaurora.org> (raw)
In-Reply-To: <3e529862-7790-c506-abaa-9a6972f5d53c@acm.org>
On 2020-02-05 14:21, Bart Van Assche wrote:
> On 2020-02-04 22:06, Can Guo wrote:
>> @@ -5617,7 +5622,7 @@ static irqreturn_t ufshcd_check_errors(struct
>>
>> __func__, hba->saved_err,
>> hba->saved_uic_err);
>>
>> - ufshcd_print_host_regs(hba);
>> + __ufshcd_print_host_regs(hba, true);
>> ufshcd_print_pwr_info(hba);
>> ufshcd_print_tmrs(hba,
>> hba->outstanding_tasks);
>> ufshcd_print_trs(hba,
>> hba->outstanding_reqs,
>
> Hi Can,
>
> Please fix this by splitting ufs_qcom_dump_dbg_regs() into two
> functions: one function that doesn't sleep and a second function that
> behaves identically to the current function. If the function names will
> make it clear which function sleeps and which function doesn't that
> will
> result in code that is much easier to read than the above code. For the
> above code it is namely impossible to figure out what will happen
> without looking up the caller.
>
> Thanks,
>
> Bart.
Hi Bart,
Do you mean by splitting ufshcd_print_host_regs() into two functions?
One behaves identically same to the current function, another one called
ufshcd_print_host_regs_nosleep(). No?
Thanks,
Can Guo.
next prev parent reply other threads:[~2020-02-05 6:31 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-02-05 6:06 [PATCH] scsi: ufs: Fix registers dump vops caused scheduling while atomic Can Guo
2020-02-05 6:21 ` Bart Van Assche
2020-02-05 6:31 ` Can Guo [this message]
2020-02-05 22:45 ` Bart Van Assche
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=749a1db94df00278ec9f5c121cd937fe@codeaurora.org \
--to=cang@codeaurora.org \
--cc=agross@kernel.org \
--cc=alim.akhtar@samsung.com \
--cc=asutoshd@codeaurora.org \
--cc=avri.altman@wdc.com \
--cc=beanhuo@micron.com \
--cc=bjorn.andersson@linaro.org \
--cc=bvanassche@acm.org \
--cc=hongwus@codeaurora.org \
--cc=jejb@linux.ibm.com \
--cc=kernel-team@android.com \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
--cc=martin.petersen@oracle.com \
--cc=nguyenb@codeaurora.org \
--cc=rnayak@codeaurora.org \
--cc=salyzyn@google.com \
--cc=saravanak@google.com \
--cc=stanley.chu@mediatek.com \
--cc=tomas.winkler@intel.com \
--cc=venkatg@codeaurora.org \
/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.