<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-toradex.git/drivers/thunderbolt/switch.c, branch v4.9.16</title>
<subtitle>Linux kernel for Apalis and Colibri modules</subtitle>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/'/>
<entry>
<title>thunderbolt: Don't declare Falcon Ridge unsupported</title>
<updated>2016-08-31T11:25:02+00:00</updated>
<author>
<name>Lukas Wunner</name>
<email>lukas@wunner.de</email>
</author>
<published>2016-08-03T08:44:12+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=ccdf3b888d87df1b914fedde91ed1848f0651c65'/>
<id>ccdf3b888d87df1b914fedde91ed1848f0651c65</id>
<content type='text'>
Falcon Ridge 4C has been supported by the driver from the beginning,
Falcon Ridge 2C support was just added. Don't irritate users with a
warning declaring the opposite.

Signed-off-by: Lukas Wunner &lt;lukas@wunner.de&gt;
Signed-off-by: Andreas Noever &lt;andreas.noever@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Falcon Ridge 4C has been supported by the driver from the beginning,
Falcon Ridge 2C support was just added. Don't irritate users with a
warning declaring the opposite.

Signed-off-by: Lukas Wunner &lt;lukas@wunner.de&gt;
Signed-off-by: Andreas Noever &lt;andreas.noever@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>thunderbolt: Support 1st gen Light Ridge controller</title>
<updated>2016-04-08T16:13:40+00:00</updated>
<author>
<name>Lukas Wunner</name>
<email>lukas@wunner.de</email>
</author>
<published>2016-03-20T12:57:20+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=19bf4d4f909d644110cb587545dc385044ac90a4'/>
<id>19bf4d4f909d644110cb587545dc385044ac90a4</id>
<content type='text'>
Add support for the 1st gen Light Ridge controller, which is built into
these systems:

  iMac12,1       2011  21.5"
  iMac12,2       2011  27"
  Macmini5,1     2011  i5 2.3 GHz
  Macmini5,2     2011  i5 2.5 GHz
  Macmini5,3     2011  i7 2.0 GHz
  MacBookPro8,1  2011  13"
  MacBookPro8,2  2011  15"
  MacBookPro8,3  2011  17"
  MacBookPro9,1  2012  15"
  MacBookPro9,2  2012  13"

Light Ridge (CV82524) was the very first copper Thunderbolt controller,
introduced 2010 alongside its fiber-optic cousin Light Peak (CVL2510).
Consequently the chip suffers from some teething troubles:

  - MSI is broken for hotplug signaling on the downstream bridges: The chip
    just never sends an interrupt.  It requests 32 MSIs for each of its six
    bridges and the pcieport driver only allocates one per bridge.  However
    I've verified that even if 32 MSIs are allocated there's no interrupt
    on hotplug.  The only option is thus to disable MSI, which is also what
    OS X does.  Apparently all Thunderbolt chips up to revision 1 of Cactus
    Ridge 4C are plagued by this issue so quirk those as well.

  - The chip supports a maximum hop_count of 32, unlike its successors
    which support only 12.  Fixup ring_interrupt_active() to cope with
    values &gt;= 32.

  - Another peculiarity is that the chip supports a maximum of 13 ports
    whereas its successors support 12.  However the additional port (#5)
    seems to be unusable as reading its TB_CFG_PORT config space results in
    TB_CFG_ERROR_INVALID_CONFIG_SPACE.  Add a quirk to mark the port
    disabled on the root switch, assuming that's necessary on all Macs
    using this chip.

Tested-by: Lukas Wunner &lt;lukas@wunner.de&gt; [MacBookPro9,1]
Tested-by: William Brown &lt;william@blackhats.net.au&gt; [MacBookPro8,2]
Signed-off-by: Lukas Wunner &lt;lukas@wunner.de&gt;
Signed-off-by: Bjorn Helgaas &lt;bhelgaas@google.com&gt;
Acked-by: Andreas Noever &lt;andreas.noever@gmail.com&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add support for the 1st gen Light Ridge controller, which is built into
these systems:

  iMac12,1       2011  21.5"
  iMac12,2       2011  27"
  Macmini5,1     2011  i5 2.3 GHz
  Macmini5,2     2011  i5 2.5 GHz
  Macmini5,3     2011  i7 2.0 GHz
  MacBookPro8,1  2011  13"
  MacBookPro8,2  2011  15"
  MacBookPro8,3  2011  17"
  MacBookPro9,1  2012  15"
  MacBookPro9,2  2012  13"

Light Ridge (CV82524) was the very first copper Thunderbolt controller,
introduced 2010 alongside its fiber-optic cousin Light Peak (CVL2510).
Consequently the chip suffers from some teething troubles:

  - MSI is broken for hotplug signaling on the downstream bridges: The chip
    just never sends an interrupt.  It requests 32 MSIs for each of its six
    bridges and the pcieport driver only allocates one per bridge.  However
    I've verified that even if 32 MSIs are allocated there's no interrupt
    on hotplug.  The only option is thus to disable MSI, which is also what
    OS X does.  Apparently all Thunderbolt chips up to revision 1 of Cactus
    Ridge 4C are plagued by this issue so quirk those as well.

  - The chip supports a maximum hop_count of 32, unlike its successors
    which support only 12.  Fixup ring_interrupt_active() to cope with
    values &gt;= 32.

  - Another peculiarity is that the chip supports a maximum of 13 ports
    whereas its successors support 12.  However the additional port (#5)
    seems to be unusable as reading its TB_CFG_PORT config space results in
    TB_CFG_ERROR_INVALID_CONFIG_SPACE.  Add a quirk to mark the port
    disabled on the root switch, assuming that's necessary on all Macs
    using this chip.

Tested-by: Lukas Wunner &lt;lukas@wunner.de&gt; [MacBookPro9,1]
Tested-by: William Brown &lt;william@blackhats.net.au&gt; [MacBookPro8,2]
Signed-off-by: Lukas Wunner &lt;lukas@wunner.de&gt;
Signed-off-by: Bjorn Helgaas &lt;bhelgaas@google.com&gt;
Acked-by: Andreas Noever &lt;andreas.noever@gmail.com&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>thunderbolt: Fix typos and magic number</title>
<updated>2016-04-08T16:09:34+00:00</updated>
<author>
<name>Lukas Wunner</name>
<email>lukas@wunner.de</email>
</author>
<published>2016-03-20T12:57:20+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=aae20bb6b45e0666c63506053c40f71c0c34cba0'/>
<id>aae20bb6b45e0666c63506053c40f71c0c34cba0</id>
<content type='text'>
Fix typo in tb_cfg_print_error() message.  Fix bytecount in struct
tb_drom_entry_port comment.  Replace magic number in tb_switch_alloc().
Rename tb_sw_set_unpplugged() and TB_CAL_IECS to fix typos.

[bhelgaas: no functional change intended]
Signed-off-by: Lukas Wunner &lt;lukas@wunner.de&gt;
Signed-off-by: Bjorn Helgaas &lt;bhelgaas@google.com&gt;
Acked-by: Andreas Noever &lt;andreas.noever@gmail.com&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fix typo in tb_cfg_print_error() message.  Fix bytecount in struct
tb_drom_entry_port comment.  Replace magic number in tb_switch_alloc().
Rename tb_sw_set_unpplugged() and TB_CAL_IECS to fix typos.

[bhelgaas: no functional change intended]
Signed-off-by: Lukas Wunner &lt;lukas@wunner.de&gt;
Signed-off-by: Bjorn Helgaas &lt;bhelgaas@google.com&gt;
Acked-by: Andreas Noever &lt;andreas.noever@gmail.com&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>PCI: Add Intel Thunderbolt device IDs</title>
<updated>2016-04-08T16:08:12+00:00</updated>
<author>
<name>Lukas Wunner</name>
<email>lukas@wunner.de</email>
</author>
<published>2016-03-20T12:57:20+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=1d111406c6d91f4d7f6cc69a43e59546e8010aae'/>
<id>1d111406c6d91f4d7f6cc69a43e59546e8010aae</id>
<content type='text'>
Intel Gen 1 and 2 chips use the same ID for NHI, bridges and switch.  Gen 3
chips and onward use a distinct ID for the NHI.

No functional change intended.

Signed-off-by: Lukas Wunner &lt;lukas@wunner.de&gt;
Signed-off-by: Bjorn Helgaas &lt;bhelgaas@google.com&gt;
Acked-by: Andreas Noever &lt;andreas.noever@gmail.com&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Intel Gen 1 and 2 chips use the same ID for NHI, bridges and switch.  Gen 3
chips and onward use a distinct ID for the NHI.

No functional change intended.

Signed-off-by: Lukas Wunner &lt;lukas@wunner.de&gt;
Signed-off-by: Bjorn Helgaas &lt;bhelgaas@google.com&gt;
Acked-by: Andreas Noever &lt;andreas.noever@gmail.com&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>thunderbolt: Use NULL instead of 0 in switch.c</title>
<updated>2014-06-20T16:44:42+00:00</updated>
<author>
<name>Sachin Kamat</name>
<email>sachin.kamat@samsung.com</email>
</author>
<published>2014-06-20T09:02:31+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=c9c2deef457c766a33c4862c9c198c20854d5fb6'/>
<id>c9c2deef457c766a33c4862c9c198c20854d5fb6</id>
<content type='text'>
The function returns a pointer. Hence return NULL instead of 0.

Signed-off-by: Sachin Kamat &lt;sachin.kamat@samsung.com&gt;
Acked-by: Andreas Noever &lt;andreas.noever@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The function returns a pointer. Hence return NULL instead of 0.

Signed-off-by: Sachin Kamat &lt;sachin.kamat@samsung.com&gt;
Acked-by: Andreas Noever &lt;andreas.noever@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>thunderbolt: Fix build error in switch.c</title>
<updated>2014-06-20T16:44:42+00:00</updated>
<author>
<name>Sachin Kamat</name>
<email>sachin.kamat@samsung.com</email>
</author>
<published>2014-06-20T09:02:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=10fefe56bba413fb0525207c65cf50cf2a5afaff'/>
<id>10fefe56bba413fb0525207c65cf50cf2a5afaff</id>
<content type='text'>
Fixes the below error:
drivers/thunderbolt/switch.c:347:2: error: implicit declaration of function ‘kzalloc’ [-Werror=implicit-function-declaration]
drivers/thunderbolt/switch.c:381:2: error: implicit declaration of function ‘kcalloc’ [-Werror=implicit-function-declaration]

Signed-off-by: Sachin Kamat &lt;sachin.kamat@samsung.com&gt;
Acked-by: Andreas Noever &lt;andreas.noever@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fixes the below error:
drivers/thunderbolt/switch.c:347:2: error: implicit declaration of function ‘kzalloc’ [-Werror=implicit-function-declaration]
drivers/thunderbolt/switch.c:381:2: error: implicit declaration of function ‘kcalloc’ [-Werror=implicit-function-declaration]

Signed-off-by: Sachin Kamat &lt;sachin.kamat@samsung.com&gt;
Acked-by: Andreas Noever &lt;andreas.noever@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>thunderbolt: Fix nontrivial endpoint devices.</title>
<updated>2014-06-19T21:14:35+00:00</updated>
<author>
<name>Andreas Noever</name>
<email>andreas.noever@gmail.com</email>
</author>
<published>2014-06-12T21:11:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=343fcb8c70d76967ba64493ca984e40baad9d0f6'/>
<id>343fcb8c70d76967ba64493ca984e40baad9d0f6</id>
<content type='text'>
Fix issues observed with the Startech docking station:

Fix the type of the route parameter in tb_ctl_rx. It should be u64 and not
u8 (which only worked for short routes).

A thunderbolt cable contains two lanes. If both endpoints support it a
connection will be established on both lanes. Previously we tried to
scan below both "dual link ports". Use the information extracted from
the drom to only scan behind ports with lane_nr == 0.

Endpoints with more complex thunderbolt controllers have some of their
ports disabled (for example the NHI port or one of the HDMI/DP ports).
Accessing them results in an error so we now ignore ports which are
marked as disabled in the drom.

Signed-off-by: Andreas Noever &lt;andreas.noever@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fix issues observed with the Startech docking station:

Fix the type of the route parameter in tb_ctl_rx. It should be u64 and not
u8 (which only worked for short routes).

A thunderbolt cable contains two lanes. If both endpoints support it a
connection will be established on both lanes. Previously we tried to
scan below both "dual link ports". Use the information extracted from
the drom to only scan behind ports with lane_nr == 0.

Endpoints with more complex thunderbolt controllers have some of their
ports disabled (for example the NHI port or one of the HDMI/DP ports).
Accessing them results in an error so we now ignore ports which are
marked as disabled in the drom.

Signed-off-by: Andreas Noever &lt;andreas.noever@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>thunderbolt: Read port configuration from eeprom.</title>
<updated>2014-06-19T21:14:35+00:00</updated>
<author>
<name>Andreas Noever</name>
<email>andreas.noever@gmail.com</email>
</author>
<published>2014-06-12T21:11:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=cd22e73bdf5eff7e68a0f8bdfbce123ad43651f6'/>
<id>cd22e73bdf5eff7e68a0f8bdfbce123ad43651f6</id>
<content type='text'>
All Thunderbolt switches (except the root switch) contain a drom which
contains information about the device. Right now we only read the UID.

Add code to read and parse this drom. For now we are only interested in
which ports are disabled and which ports are "dual link ports" (a
physical thunderbolt port/socket contains two such ports).

Signed-off-by: Andreas Noever &lt;andreas.noever@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
All Thunderbolt switches (except the root switch) contain a drom which
contains information about the device. Right now we only read the UID.

Add code to read and parse this drom. For now we are only interested in
which ports are disabled and which ports are "dual link ports" (a
physical thunderbolt port/socket contains two such ports).

Signed-off-by: Andreas Noever &lt;andreas.noever@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>thunderbolt: Add suspend/hibernate support</title>
<updated>2014-06-19T21:13:00+00:00</updated>
<author>
<name>Andreas Noever</name>
<email>andreas.noever@gmail.com</email>
</author>
<published>2014-06-03T20:04:12+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=23dd5bb49d986f37977ed80dd2ca65040ead4392'/>
<id>23dd5bb49d986f37977ed80dd2ca65040ead4392</id>
<content type='text'>
We use _noirq since we have to restore the pci tunnels before the pci
core wakes the tunneled devices.

Signed-off-by: Andreas Noever &lt;andreas.noever@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
We use _noirq since we have to restore the pci tunnels before the pci
core wakes the tunneled devices.

Signed-off-by: Andreas Noever &lt;andreas.noever@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>thunderbolt: Read switch uid from EEPROM</title>
<updated>2014-06-19T21:13:00+00:00</updated>
<author>
<name>Andreas Noever</name>
<email>andreas.noever@gmail.com</email>
</author>
<published>2014-06-03T20:04:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=c90553b3c4ac2389a71a5c012b6e5bb1160d48a7'/>
<id>c90553b3c4ac2389a71a5c012b6e5bb1160d48a7</id>
<content type='text'>
Add eeprom access code and read the uid during switch initialization.
The UID will be used to check device identity after suspend.

Signed-off-by: Andreas Noever &lt;andreas.noever@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add eeprom access code and read the uid during switch initialization.
The UID will be used to check device identity after suspend.

Signed-off-by: Andreas Noever &lt;andreas.noever@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
</feed>
