Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1482297 > unrolled thread

[Question] Calling request_firmware under the spinlocks in file advansys.c

Started byVaishali Thakkar <vaishali.thakkar@oracle.com>
First post2016-09-13 11:30 +0200
Last post2016-09-13 11:30 +0200
Articles 1 — 1 participant

Back to article view | Back to linux.kernel


Contents

  [Question] Calling request_firmware under the spinlocks in file  advansys.c Vaishali Thakkar <vaishali.thakkar@oracle.com> - 2016-09-13 11:30 +0200

#1482297 — [Question] Calling request_firmware under the spinlocks in file advansys.c

FromVaishali Thakkar <vaishali.thakkar@oracle.com>
Date2016-09-13 11:30 +0200
Subject[Question] Calling request_firmware under the spinlocks in file advansys.c
Message-ID<sgScp-8ns-17@gated-at.bofh.it>
Hi,

In the file drivers/scsi/advansys.c we are calling function AdvISR at 2 instances
[in the function advansys_reset and advansys_interrupt] while holding spinlock.
Function AdvISR eventually calls request_firmware following this sequence of
routines: 

AdvISR -> adv_async_callback -> AdvResetChipAndSB -> AdvInitAsc3550Driver ->
request_firmware

According to the definition of request_firmware it should be called from user
context where sleeping is allowed. And usually sleeping under the spin lock is
not allowed. Is it really necessary to call AdvISR under spinlocks here? Are
we taking care of sleeping related concern of request_firmware or am I
overlooking something here?

Thank you.

-- 
Vaishali

[toc] | [standalone]


Back to top | Article view | linux.kernel


csiph-web