Re: [PATCH] IB/core: export struct ib_port

2009-11-12 Thread Roland Dreier
| While this is true for SLtoVL, we create other files which are | device specific under the port directory too. | It seems like we might need to introduce a callback into the driver to | create the port specific sysfs files. | | Umm, you could have said there were other

Re: [PATCH] IB/core: export struct ib_port

2009-11-11 Thread Roland Dreier
This patch moves the definition of struct ib_port from sysfs.c to ib_verbs.h so that HCAs can create files in /sys/class/infiniband/hca/ports/N/ um, maybe, but we need to see how it gets used first. How do you get the to struct ib_port in driver code? Maybe it would make more sense to

Re: [PATCH] IB/core: export struct ib_port

2009-11-11 Thread Ralph Campbell
On Wed, 2009-11-11 at 11:19 -0800, Roland Dreier wrote: This patch moves the definition of struct ib_port from sysfs.c to ib_verbs.h so that HCAs can create files in /sys/class/infiniband/hca/ports/N/ um, maybe, but we need to see how it gets used first. How do you get the to struct

Re: [PATCH] IB/core: export struct ib_port

2009-11-11 Thread Roland Dreier
It is used by the new ib_qib driver to expose the SL to VL table since the user level MPI library (libpsm) constructs packets including the IB header. After the driver calls ib_register_device(), it calls device_create_file() to create the files in /sys/class/infiniband/qib0/. Then it

Re: [PATCH] IB/core: export struct ib_port

2009-11-11 Thread Dave Olson
On Wed, 11 Nov 2009, Roland Dreier wrote: | It is used by the new ib_qib driver to expose the SL to VL table | since the user level MPI library (libpsm) constructs packets including | the IB header. After the driver calls ib_register_device(), | it calls device_create_file() to create the

Re: ipath now and then (was [PATCH] IB/core: export struct ib_port)

2009-11-11 Thread Or Gerlitz
On Wed, Nov 11, 2009 at 11:06 PM, Dave Olson dave.ol...@qlogic.com wrote: And yes, the ib_ipath is being fully deprecated.  The full set of patches that adds ib_qib upstream will include a subset that drops ib_ipath.   All the bug fixes and feature work have been done for ib_qib It was brought

Re: [PATCH] IB/core: export struct ib_port

2009-11-11 Thread Roland Dreier
| Hmm, maybe we should just add a vls directory with sl0 ... sl15 or | something like that in generic code? I don't see why this needs to be | driver-specific code. No particular reason, it just didn't seem likely to be useful on other HCA drivers. I can redo the patches that way,

Re: [PATCH] IB/core: export struct ib_port

2009-11-11 Thread Ralph Campbell
On Wed, 2009-11-11 at 15:02 -0800, Roland Dreier wrote: | Hmm, maybe we should just add a vls directory with sl0 ... sl15 or | something like that in generic code? I don't see why this needs to be | driver-specific code. No particular reason, it just didn't seem likely to be useful

Re: [PATCH] IB/core: export struct ib_port

2009-11-11 Thread Jason Gunthorpe
On Wed, Nov 11, 2009 at 03:22:50PM -0800, Ralph Campbell wrote: While this is true for SLtoVL, we create other files which are device specific under the port directory too. It seems like we might need to introduce a callback into the driver to create the port specific sysfs files. Maybe give

Re: [PATCH] IB/core: export struct ib_port

2009-11-11 Thread Roland Dreier
Maybe give some thought to using a syscall interface through uverbs for some of this? Actually I think for exposing SL-to-VL and other things like that, sysfs is pretty good. Having something usable from both scripts and programs seems pretty useful, and having an opaque uverbs interface

Re: [PATCH] IB/core: export struct ib_port

2009-11-11 Thread Dave Olson
On Wed, 11 Nov 2009, Roland Dreier wrote: | | While this is true for SLtoVL, we create other files which are | device specific under the port directory too. | It seems like we might need to introduce a callback into the driver to | create the port specific sysfs files. | | Umm, you