* [PATCH] cciss 2.6: pci domain info
@ 2005-06-17 18:31 mike.miller
2005-06-17 19:34 ` Christoph Hellwig
2005-06-17 19:35 ` Matthew Wilcox
0 siblings, 2 replies; 4+ messages in thread
From: mike.miller @ 2005-06-17 18:31 UTC (permalink / raw)
To: akpm, axboe; +Cc: linux-kernel, linux-scsi
This patch adds pci domain info to our CCISS_GETPCIINFO ioctl. This is to support the next generation of Itanium platforms. We had a couple of spare bytes in the structure. Impact to existing apps should be minimal. Please consider this patch for inclusion.
Signed-off-by: Mike Miller <mike.miller@hp.com>
drivers/block/cciss.c | 1 +
include/linux/cciss_ioctl.h | 1 +
2 files changed, 2 insertions(+)
--------------------------------------------------------------------------------
diff -burNp lx2612-rc6.orig/drivers/block/cciss.c lx2612-rc6/drivers/block/cciss.c
--- lx2612-rc6.orig/drivers/block/cciss.c 2005-06-14 12:04:34.000000000 -0500
+++ lx2612-rc6/drivers/block/cciss.c 2005-06-17 13:04:52.384575144 -0500
@@ -636,6 +636,7 @@ static int cciss_ioctl(struct inode *ino
cciss_pci_info_struct pciinfo;
if (!arg) return -EINVAL;
+ pciinfo.domain = pci_domain_nr(host->pdev->bus);
pciinfo.bus = host->pdev->bus->number;
pciinfo.dev_fn = host->pdev->devfn;
pciinfo.board_id = host->board_id;
diff -burNp lx2612-rc6.orig/include/linux/cciss_ioctl.h lx2612-rc6/include/linux/cciss_ioctl.h
--- lx2612-rc6.orig/include/linux/cciss_ioctl.h 2005-03-02 01:38:07.000000000 -0600
+++ lx2612-rc6/include/linux/cciss_ioctl.h 2005-06-17 13:06:42.082898464 -0500
@@ -9,6 +9,7 @@
typedef struct _cciss_pci_info_struct
{
+ unsigned int domain;
unsigned char bus;
unsigned char dev_fn;
__u32 board_id;
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] cciss 2.6: pci domain info
2005-06-17 18:31 [PATCH] cciss 2.6: pci domain info mike.miller
@ 2005-06-17 19:34 ` Christoph Hellwig
2005-06-17 19:35 ` Matthew Wilcox
1 sibling, 0 replies; 4+ messages in thread
From: Christoph Hellwig @ 2005-06-17 19:34 UTC (permalink / raw)
To: mike.miller; +Cc: akpm, axboe, linux-kernel, linux-scsi
On Fri, Jun 17, 2005 at 01:31:24PM -0500, mike.miller@hp.com wrote:
> This patch adds pci domain info to our CCISS_GETPCIINFO ioctl. This is to support the next generation of Itanium platforms. We had a couple of spare bytes in the structure. Impact to existing apps should be minimal. Please consider this patch for inclusion.
I don't think an unsigned int fits into padding of any platform.
> Signed-off-by: Mike Miller <mike.miller@hp.com>
>
> drivers/block/cciss.c | 1 +
> include/linux/cciss_ioctl.h | 1 +
> 2 files changed, 2 insertions(+)
> --------------------------------------------------------------------------------
> diff -burNp lx2612-rc6.orig/drivers/block/cciss.c lx2612-rc6/drivers/block/cciss.c
> --- lx2612-rc6.orig/drivers/block/cciss.c 2005-06-14 12:04:34.000000000 -0500
> +++ lx2612-rc6/drivers/block/cciss.c 2005-06-17 13:04:52.384575144 -0500
> @@ -636,6 +636,7 @@ static int cciss_ioctl(struct inode *ino
> cciss_pci_info_struct pciinfo;
>
> if (!arg) return -EINVAL;
> + pciinfo.domain = pci_domain_nr(host->pdev->bus);
> pciinfo.bus = host->pdev->bus->number;
> pciinfo.dev_fn = host->pdev->devfn;
> pciinfo.board_id = host->board_id;
> diff -burNp lx2612-rc6.orig/include/linux/cciss_ioctl.h lx2612-rc6/include/linux/cciss_ioctl.h
> --- lx2612-rc6.orig/include/linux/cciss_ioctl.h 2005-03-02 01:38:07.000000000 -0600
> +++ lx2612-rc6/include/linux/cciss_ioctl.h 2005-06-17 13:06:42.082898464 -0500
> @@ -9,6 +9,7 @@
>
> typedef struct _cciss_pci_info_struct
> {
> + unsigned int domain;
> unsigned char bus;
> unsigned char dev_fn;
> __u32 board_id;
> -
> To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
---end quoted text---
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] cciss 2.6: pci domain info
2005-06-17 18:31 [PATCH] cciss 2.6: pci domain info mike.miller
2005-06-17 19:34 ` Christoph Hellwig
@ 2005-06-17 19:35 ` Matthew Wilcox
1 sibling, 0 replies; 4+ messages in thread
From: Matthew Wilcox @ 2005-06-17 19:35 UTC (permalink / raw)
To: mike.miller; +Cc: akpm, axboe, linux-kernel, linux-scsi
On Fri, Jun 17, 2005 at 01:31:24PM -0500, mike.miller@hp.com wrote:
> This patch adds pci domain info to our CCISS_GETPCIINFO ioctl. This
> is to support the next generation of Itanium platforms. We had a couple
> of spare bytes in the structure. Impact to existing apps should be
> minimal. Please consider this patch for inclusion.
> typedef struct _cciss_pci_info_struct
> {
> + unsigned int domain;
> unsigned char bus;
> unsigned char dev_fn;
> __u32 board_id;
Um, what? There's no way this doesn't break the ABI. You do have spare
bytes in the struct, but to use them, you have to add an 'unsigned short'
between dev_fn and board_id:
typedef struct _cciss_pci_info_struct
{
unsigned char bus;
unsigned char dev_fn;
+ unsigned int domain;
__u32 board_id;
}
--
"Next the statesmen will invent cheap lies, putting the blame upon
the nation that is attacked, and every man will be glad of those
conscience-soothing falsities, and will diligently study them, and refuse
to examine any refutations of them; and thus he will by and by convince
himself that the war is just, and will thank God for the better sleep
he enjoys after this process of grotesque self-deception." -- Mark Twain
^ permalink raw reply [flat|nested] 4+ messages in thread
* RE: [PATCH] cciss 2.6: pci domain info
@ 2005-06-17 19:40 Miller, Mike (OS Dev)
0 siblings, 0 replies; 4+ messages in thread
From: Miller, Mike (OS Dev) @ 2005-06-17 19:40 UTC (permalink / raw)
To: Christoph Hellwig; +Cc: akpm, axboe, linux-kernel, linux-scsi
Christoph wrote:
>
> On Fri, Jun 17, 2005 at 01:31:24PM -0500, mike.miller@hp.com wrote:
> > This patch adds pci domain info to our CCISS_GETPCIINFO
> ioctl. This is to support the next generation of Itanium
> platforms. We had a couple of spare bytes in the structure.
> Impact to existing apps should be minimal. Please consider
> this patch for inclusion.
>
> I don't think an unsigned int fits into padding of any platform.
How about 'unsigned short' as Willy suggested?
mikem
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2005-06-17 19:43 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-06-17 18:31 [PATCH] cciss 2.6: pci domain info mike.miller
2005-06-17 19:34 ` Christoph Hellwig
2005-06-17 19:35 ` Matthew Wilcox
2005-06-17 19:40 Miller, Mike (OS Dev)
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®