Re: [PATCH -mm 0/2] RapidIO: Changes to handling of RIO switches

From: Micha Nelissen
Date: Fri Oct 22 2010 - 17:59:12 EST


Bounine, Alexandre wrote:
Micha Nelissen <micha@xxxxxxxxxxxxxx> wrote:
rswitch->rdev->destid should be the id associated with a given switch,
so that every (processor) device can agree what id some switch has.

If we will need to identify the same physical switch by different
processors we may use the component tag which now is unique for every
device.

Yes, identification is the point. I think it might be confusing to have a destid *and* a component tag id which are slightly different. The destid is unambiguous (if you know whether the device is a switch or endpoint) so I think it makes sense to use that if possible.

This actually gives me another idea: instead of using global
next_switchid counter make rswitch->switchid = component_tag and
switches in sysfs will look identical for every processor (or just get
rid of rswitch->switchid and use component_tag directly for switches).

I still prefer the destid as the single identification id.

Micha
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/