Alexander Schmidt wrote: > Hi Vlad, > > please apply for OFED-151. > > Forward ports for ehca driver to enable compilation > on 2.6.32 and 2.6.31. > > Signed-off-by: Alexander Schmidt <al...@linux.vnet.ibm.com> > --- > kernel_patches/backport/2.6.32/ehca-010-remove_driver_data.patch | 60 > ++++++++++ > kernel_patches/backport/2.6.32/ehca-020-fix_buswalk.patch | 17 ++ > 2 files changed, 77 insertions(+) >
Hi Alex, I don't see patches for 2.6.31. Should they be here? Regards, Vladimir > --- /dev/null > +++ > ofed_kernel-1.5/kernel_patches/backport/2.6.32/ehca-010-remove_driver_data.patch > @@ -0,0 +1,60 @@ > +commit f899c2ddd45f2515deb446e2b143e4a686a49aee > +Author: Greg Kroah-Hartman <gre...@suse.de> > +Date: Mon May 4 12:40:54 2009 -0700 > + > + infiniband: ehca: remove driver_data direct access of struct device > + > + In the near future, the driver core is going to not allow direct access > + to the driver_data pointer in struct device. Instead, the functions > + dev_get_drvdata() and dev_set_drvdata() should be used. These functions > + have been around since the beginning, so are backwards compatible with > + all older kernel versions. > + > + Cc: Sean Hefty <sean.he...@intel.com> > + Cc: Roland Dreier <rola...@cisco.com> > + Cc: Hal Rosenstock <hal.rosenst...@gmail.com> > + Cc: gene...@lists.openfabrics.org > + Cc: Christoph Raisch <rai...@de.ibm.com> > + Acked-by: Hoang-Nam Nguyen <hngu...@de.ibm.com> > + Signed-off-by: Greg Kroah-Hartman <gre...@suse.de> > + > +diff --git a/drivers/infiniband/hw/ehca/ehca_main.c > b/drivers/infiniband/hw/ehca/ehca_main.c > +index 85905ab..ce4e6ef 100644 > +--- a/drivers/infiniband/hw/ehca/ehca_main.c > ++++ b/drivers/infiniband/hw/ehca/ehca_main.c > +@@ -636,7 +636,7 @@ static ssize_t ehca_show_##name(struct device *dev, > \ > + struct hipz_query_hca *rblock; \ > + int data; \ > + \ > +- shca = dev->driver_data; \ > ++ shca = dev_get_drvdata(dev); \ > + \ > + rblock = ehca_alloc_fw_ctrlblock(GFP_KERNEL); \ > + if (!rblock) { \ > +@@ -680,7 +680,7 @@ static ssize_t ehca_show_adapter_handle(struct device > *dev, > + struct device_attribute *attr, > + char *buf) > + { > +- struct ehca_shca *shca = dev->driver_data; > ++ struct ehca_shca *shca = dev_get_drvdata(dev); > + > + return sprintf(buf, "%llx\n", shca->ipz_hca_handle.handle); > + > +@@ -749,7 +749,7 @@ static int __devinit ehca_probe(struct of_device *dev, > + > + shca->ofdev = dev; > + shca->ipz_hca_handle.handle = *handle; > +- dev->dev.driver_data = shca; > ++ dev_set_drvdata(&dev->dev, shca); > + > + ret = ehca_sense_attributes(shca); > + if (ret < 0) { > +@@ -878,7 +878,7 @@ probe1: > + > + static int __devexit ehca_remove(struct of_device *dev) > + { > +- struct ehca_shca *shca = dev->dev.driver_data; > ++ struct ehca_shca *shca = dev_get_drvdata(&dev->dev); > + unsigned long flags; > + int ret; > + > --- /dev/null > +++ ofed_kernel-1.5/kernel_patches/backport/2.6.32/ehca-020-fix_buswalk.patch > @@ -0,0 +1,17 @@ > +--- > + drivers/infiniband/hw/ehca/ehca_mrmw.c | 2 +- > + 1 file changed, 1 insertion(+), 1 deletion(-) > + > +Index: ofa_kernel-1.5.1/drivers/infiniband/hw/ehca/ehca_mrmw.c > +=================================================================== > +--- ofa_kernel-1.5.1.orig/drivers/infiniband/hw/ehca/ehca_mrmw.c > ++++ ofa_kernel-1.5.1/drivers/infiniband/hw/ehca/ehca_mrmw.c > +@@ -2463,7 +2463,7 @@ int ehca_create_busmap(void) > + int ret; > + > + ehca_mr_len = 0; > +- ret = walk_memory_resource(0, 1ULL << MAX_PHYSMEM_BITS, NULL, > ++ ret = walk_system_ram_range(0, 1ULL << MAX_PHYSMEM_BITS, NULL, > + ehca_create_busmap_callback); > + return ret; > + } > _______________________________________________ ewg mailing list ewg@lists.openfabrics.org http://lists.openfabrics.org/cgi-bin/mailman/listinfo/ewg