mpt2sas: _scsih_smart_predicted_fault uses GFP_KERNEL in interrupt context
_scsih_smart_predicted_fault is called in an interrupt and therefore must allocate memory using GFP_ATOMIC.
---
drivers/scsi/mpt2sas/mpt2sas_scsih.c +1 -1
@@ -4210,7 +4210,7 @@ _scsih_smart_predicted_fault(struct MPT2/* insert into event log */ sz = offsetof(Mpi2EventNotificationReply_t , EventData) +sizeof (Mpi2EventDataSasDeviceStatusChange_t); - event_reply =kzalloc (sz,GFP_KERNEL ); + event_reply =kzalloc (sz,GFP_ATOMIC );if (!event_reply) {printk (MPT2SAS_ERR_FMT "failure at %s:%d/%s()!\n" , ioc->name, __FILE__, __LINE__, __func__);
Hi Kashyap,
Quoted 3 lines · On Sun, 31 Jul 2011 19:29:09 +1000 Anton Blanchard <[email protected]> wrote:
_scsih_smart_predicted_faultis called in an interrupt and therefore must allocate memory usingGFP_ATOMIC.
Just noticed this hasn't made it upstream, any chance you could review it for merging?
Anton
--
_scsih_smart_predicted_fault is called in an interrupt and therefore must allocate memory using GFP_ATOMIC.
---
drivers/scsi/mpt2sas/mpt2sas_scsih.c +1 -1
@@ -4330,7 +4330,7 @@ _scsih_smart_predicted_fault(struct MPT2/* insert into event log */ sz = offsetof(Mpi2EventNotificationReply_t , EventData) +sizeof (Mpi2EventDataSasDeviceStatusChange_t); - event_reply =kzalloc (sz,GFP_KERNEL ); + event_reply =kzalloc (sz,GFP_ATOMIC );if (!event_reply) {printk (MPT2SAS_ERR_FMT "failure at %s:%d/%s()!\n" , ioc->name, __FILE__, __LINE__, __func__);
The patch seem to be fine. Please consider this patch as an Acked by me
Regards,
Nagalakshmi
-----Original Message-----
From: Anton Blanchard [mailto:[email protected]]
Sent: Monday, November 07, 2011 4:35 PM
To: Desai, Kashyap
Cc: Moore, Eric; [email protected]; [email protected]
Subject: Re: [SCSI] mpt2sas: _scsih_smart_predicted_fault uses GFP_KERNEL in interrupt context
Hi Kashyap,
Quoted 3 lines · On Sun, 31 Jul 2011 19:29:09 +1000 Anton Blanchard <[email protected]> wrote:
_scsih_smart_predicted_faultis called in an interrupt and therefore must allocate memory usingGFP_ATOMIC.
Just noticed this hasn't made it upstream, any chance you could review it for merging?
Anton
--
_scsih_smart_predicted_fault is called in an interrupt and therefore must allocate memory using GFP_ATOMIC.
---
drivers/scsi/mpt2sas/mpt2sas_scsih.c +1 -1
@@ -4330,7 +4330,7 @@ _scsih_smart_predicted_fault(struct MPT2/* insert into event log */ sz = offsetof(Mpi2EventNotificationReply_t , EventData) +sizeof (Mpi2EventDataSasDeviceStatusChange_t); - event_reply =kzalloc (sz,GFP_KERNEL ); + event_reply =kzalloc (sz,GFP_ATOMIC );if (!event_reply) {printk (MPT2SAS_ERR_FMT "failure at %s:%d/%s()!\n" , ioc->name, __FILE__, __LINE__, __func__);