All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jeff Garzik <jeff@garzik.org>
To: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Cc: Andrew Morton <akpm@linux-foundation.org>,
	Linus Torvalds <torvalds@linux-foundation.org>,
	linux-ide@vger.kernel.org, LKML <linux-kernel@vger.kernel.org>,
	Alan Cox <alan@linux.intel.com>
Subject: Re: [git patches] libata updates for 2.6.34
Date: Fri, 05 Mar 2010 14:43:43 -0500	[thread overview]
Message-ID: <4B915EEF.1040307@garzik.org> (raw)
In-Reply-To: <201003051958.24987.bzolnier@gmail.com>

On 03/05/2010 01:58 PM, Bartlomiej Zolnierkiewicz wrote:
> On Monday 01 March 2010 09:23:30 pm Jeff Garzik wrote:
>
>>        libata: Pass host flags into the pci helper
>
> It introduces a subtle bug:
>
> struct ata_host {
> ...
> 	unsigned long		flags;
>
>> @@ -1642,8 +1643,8 @@ extern int ata_pci_sff_activate_host(struct ata_host *host,
>>   				     irq_handler_t irq_handler,
>>   				     struct scsi_host_template *sht);
>>   extern int ata_pci_sff_init_one(struct pci_dev *pdev,
>> -				const struct ata_port_info * const * ppi,
>> -				struct scsi_host_template *sht, void *host_priv);
>> +		const struct ata_port_info * const * ppi,
>> +		struct scsi_host_template *sht, void *host_priv, int hflags);
>
> 'int' type is not equal 'unsigned long' one on 64-bit architectures.

True but largely irrelevant as we will never use more than 32 bits worth 
of host flags.


> Besides doing it this way is clearly suboptimal as the same effect
> could have been achieved by doing:
>
> extern int __ata_pci_sff_init_one(struct pci_dev *pdev,
> 				const struct ata_port_info * const *ppi,
> 				struct scsi_host_template *sht, void *host_priv,
> 				int hflag);
> static inline int ata_pci_sff_init_one(struct pci_dev *pdev,
> 				const struct ata_port_info * const *ppi,
> 				struct scsi_host_template *sht, void *host_priv)
> {
> 	return __ata_pci_sff_init_one(pdev, ppi, sht, host_priv, 0);
> }

This is far uglier than simply changing the API.


> without the need to update all drivers and without breaking pending
> out-of-tree driver patches (yeah, it breaks my pata_ep93xx patches)..

Every post you include a disclaimer about "my patches are not intended 
for upstream" yet you still complain?

Some people are never satisfied...

	Jeff



  parent reply	other threads:[~2010-03-05 19:43 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-03-01 20:23 [git patches] libata updates for 2.6.34 Jeff Garzik
2010-03-05 18:58 ` Bartlomiej Zolnierkiewicz
2010-03-05 18:37   ` Alan Cox
2010-03-05 19:43   ` Jeff Garzik [this message]
2010-03-05 20:12     ` Bartlomiej Zolnierkiewicz
2010-03-09 21:17 ` Linus Torvalds
2010-03-09 22:12   ` Jeff Garzik
2010-03-10  4:26     ` Tejun Heo
2010-03-12  0:16       ` Jeff Garzik
2010-03-15  2:55       ` Jeff Garzik
2010-03-15  7:33         ` Zeno Davatz
2010-03-15 13:06           ` Jeff Garzik
2010-03-15 13:21             ` Zeno Davatz
2010-03-15 13:30               ` Zeno Davatz
2010-03-15 13:32               ` Jeff Garzik
2010-03-15 13:35                 ` Zeno Davatz

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=4B915EEF.1040307@garzik.org \
    --to=jeff@garzik.org \
    --cc=akpm@linux-foundation.org \
    --cc=alan@linux.intel.com \
    --cc=bzolnier@gmail.com \
    --cc=linux-ide@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@linux-foundation.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.