Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1651911
| From | Andy Shevchenko <andy.shevchenko@gmail.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH v2 21/27] thunderbolt: Store Thunderbolt generation in the switch structure |
| Date | 2017-05-27 18:10 +0200 |
| Message-ID | <tLMrU-6fP-39@gated-at.bofh.it> (permalink) |
| References | <tLq81-87A-5@gated-at.bofh.it> <tLq84-87A-75@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Fri, May 26, 2017 at 7:09 PM, Mika Westerberg <mika.westerberg@linux.intel.com> wrote: > In some cases it is useful to know what is the Thunderbolt generation > the switch supports. This introduces a new field to struct switch that > stores the generation of the switch based on the device ID. Unknown > switches (there should be none) are assumed to be first generation to be > on the safe side. > + default: > + tb_sw_warn(sw, "unsupported switch device id %#x\n", > + sw->config.device_id); > + /* Fall through */ I would rather be explicit here. And perhaps even mention in the message we are falling back to 1. > + case PCI_DEVICE_ID_INTEL_LIGHT_RIDGE: > + case PCI_DEVICE_ID_INTEL_EAGLE_RIDGE: > + case PCI_DEVICE_ID_INTEL_LIGHT_PEAK: > + case PCI_DEVICE_ID_INTEL_CACTUS_RIDGE_2C: > + case PCI_DEVICE_ID_INTEL_CACTUS_RIDGE_4C: > + case PCI_DEVICE_ID_INTEL_PORT_RIDGE: > + case PCI_DEVICE_ID_INTEL_REDWOOD_RIDGE_2C_BRIDGE: > + case PCI_DEVICE_ID_INTEL_REDWOOD_RIDGE_4C_BRIDGE: > + return 1; Other than that FWIW: Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> -- With Best Regards, Andy Shevchenko
Back to linux.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread
[PATCH v2 21/27] thunderbolt: Store Thunderbolt generation in the switch structure Mika Westerberg <mika.westerberg@linux.intel.com> - 2017-05-26 18:20 +0200 Re: [PATCH v2 21/27] thunderbolt: Store Thunderbolt generation in the switch structure Andy Shevchenko <andy.shevchenko@gmail.com> - 2017-05-27 18:10 +0200
csiph-web