Re: [PATCH] scsi: megaraid_sas: Prevent future %p disaster

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 2015-02-10 at 22:16 +0530, Kashyap Desai wrote:
> Acked-by: Kashyap Desai <kashyap.desai@xxxxxxxxxxxxx>
> 
> > -----Original Message-----
> > From: Rasmus Villemoes [mailto:linux@xxxxxxxxxxxxxxxxxx]
> > Sent: Friday, February 06, 2015 8:04 PM
[]
> > There is currently no %po format extension, so currently the letters
> "on" are
> > simply skipped and the pointer is printed as expected (while missing the
> word
> > on). However, it is probably only a matter of time before someone comes
> up
> > with a %po extension, at which point this is likely to fail
> spectacularly.

Nice tool Rasmus

> > diff --git a/drivers/scsi/megaraid/megaraid_sas_base.c
[]
> > @@ -3105,7 +3105,7 @@ megasas_internal_reset_defer_cmds(struct
> > megasas_instance *instance)
> >  	for (i = 0; i < max_cmd; i++) {
> >  		cmd = instance->cmd_list[i];
> >  		if (cmd->sync_cmd == 1 || cmd->scmd) {
> > -			printk(KERN_NOTICE "megasas: moving
> > cmd[%d]:%p:%d:%p"
> > +			printk(KERN_NOTICE "megasas: moving
> > cmd[%d]:%p:%d:%p "
> >  					"on the defer queue as
> internal\n",
> >  				defer_index, cmd, cmd->sync_cmd, cmd-
> > >scmd);
> >

It'd probably be nicer to coalesce the format.

			printk(KERN_NOTICE "megasas: moving cmd[%d]:%p:%d:%p on the defer queue as internal\n",
				defer_ndex, cmd, cmd->sync, cmd->scmd);


--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]
  Powered by Linux