linux-ide.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Tejun Heo <htejun@gmail.com>
To: "Eric D. Mudama" <edmudama@gmail.com>
Cc: jeff@garzik.org, linux-ide@vger.kernel.org
Subject: Re: [PATCH 1/1] libata: rearrange dmesg info to add full ATA revision
Date: Wed, 31 Jan 2007 13:54:15 +0900	[thread overview]
Message-ID: <45C020F7.7000305@gmail.com> (raw)
In-Reply-To: <45C013B8.8030600@gmail.com>

[The previous replay mysteriously didn't include Eric in To:, sorry,
quoting whole message here.]

Tejun Heo wrote:
> Hello, Eric.
> 
> Eric D. Mudama wrote:
>> Per Jeff's suggestion, this patch rearranges the info printed for ATA
>> drives into dmesg to add the full ATA firmware revision and model
>> information, while keeping the output to 2 lines.
>>
>> Signed-off-by: Eric D. Mudama <edmudama@gmail.com>
> 
> The patch is formatted and applies perfectly.  I'm glad to see this
> change.  Just a few nits below.
> 
>>  	char revbuf[7];		/* XYZ-99\0 */
>> +	char fwrevbuf[9];
>> +	char modelbuf[41];
> 
> Please use ATA_ID_FW_REV_LEN + 1 and ATA_ID_PROD_LEN + 1.

This depends on to which version this patch applies.  For
#upstream-fixes (2.6.20-rc6), you have to use raw numbers as you did.
For #upstream, there are above two constants to use.  I think this patch
is good for 2.6.20 as it's safe && will help us analyzing bug reports
for 2.6.20.  So, ignore this part of the comment.

Jeff, if it gets merged into #upstream through #upstream-fixes, please
don't forget to change above constants.

>> @@ -1680,13 +1692,18 @@ int ata_dev_configure(struct ata_device *dev)
>>  			ata_dev_config_ncq(dev, ncq_desc, sizeof(ncq_desc));
>>  
>>  			/* print device info to dmesg */
>> -			if (ata_msg_drv(ap) && print_info)
>> -				ata_dev_printk(dev, KERN_INFO, "%s, "
>> -					"max %s, %Lu sectors: %s %s\n",
>> +			if (ata_msg_drv(ap) && print_info) {
>> +				ata_dev_printk(dev, KERN_INFO,
>> +					"%s: %s, %s, max %s\n",
>>  					revbuf,
>> -					ata_mode_string(xfer_mask),
>> +					modelbuf, fwrevbuf,
> 
> Please merge the above line with the line above it.
> 
>> +					ata_mode_string(xfer_mask));
>> +				ata_dev_printk(dev, KERN_INFO,
>> +					"%Lu sectors, multi %u: %s %s\n",
>>  					(unsigned long long)dev->n_sectors,
>> +					dev->multi_count,
>>  					lba_desc, ncq_desc);
> 
> Ditto.
> 
>> +			}
>>  		} else {
>>  			/* CHS */
>>  
>> @@ -1703,22 +1720,19 @@ int ata_dev_configure(struct ata_device *dev)
>>  			}
>>  
>>  			/* print device info to dmesg */
>> -			if (ata_msg_drv(ap) && print_info)
>> -				ata_dev_printk(dev, KERN_INFO, "%s, "
>> -					"max %s, %Lu sectors: CHS %u/%u/%u\n",
>> +			if (ata_msg_drv(ap) && print_info) {
>> +				ata_dev_printk(dev, KERN_INFO,
>> +					"%s: %s, %s, max %s\n",
>>  					revbuf,
>> -					ata_mode_string(xfer_mask),
>> +					modelbuf, fwrevbuf,
> 
> Ditto.
> 
>> +					ata_mode_string(xfer_mask));
>> +				ata_dev_printk(dev, KERN_INFO, 
>> +					"%Lu sectors, multi %u, CHS %u/%u/%u\n",
>>  					(unsigned long long)dev->n_sectors,
>> +					dev->multi_count,
>>  					dev->cylinders, dev->heads,
>>  					dev->sectors);
> 
> I would prefer
> 
> dev->multi_count, dev->cylinders,
> dev->heads, dev->sectors
> 
> Other than these,
> 
> Acked-by: Tejun Heo <htejun@gmail.com>
> 

-- 
tejun

  reply	other threads:[~2007-01-31  4:54 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-01-31  2:10 [PATCH 1/1] libata: rearrange dmesg info to add full ATA revision Eric D. Mudama
2007-01-31  3:57 ` Tejun Heo
2007-01-31  4:54   ` Tejun Heo [this message]
2007-01-31  9:16     ` Jeff Garzik
2007-01-31  6:00 ` Eric D. Mudama
2007-01-31 15:23   ` Jeff Garzik
2007-02-07  0:42   ` Jeff Garzik
2007-02-07  2:31     ` Eric D. Mudama

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=45C020F7.7000305@gmail.com \
    --to=htejun@gmail.com \
    --cc=edmudama@gmail.com \
    --cc=jeff@garzik.org \
    --cc=linux-ide@vger.kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).