Previously, the number of ports was only being set when setting an input port.
If there are multiple input ports, the number of ports wasn't being accurately
reflected.
The user application was required to update the number of ports when setting a
downstream port.
This is now done within the driver.
Signed-off-by: Andrei-Liviu Simion <andrei.simion@xilinx.com>
When setting the configuration of a port, always keep the port number of the
port structure to the same value as the index of the structure's index in the
port structure array.
This simplifies functions that operate on the port structure since they don't
need to search each port structure in the array for the port number, the port
number is known from the index.
Note: The existence of the port number member in the port structure is required
since the TX populates this structure when receiving LINK_ADDRESS sideband
messages.
Signed-off-by: Andrei-Liviu Simion <andrei.simion@xilinx.com>
When the upstream device issues an ALLOCATE_PAYLOAD sideband message request,
this table is updated to represent the allocated bandwidth for each stream.
Signed-off-by: Andrei-Liviu Simion <andrei.simion@xilinx.com>
The "I2C map" terminology is used to refer to a set of I2C entries for a given
port. Each I2C entry contains an I2C address associated with that entry,
alongside a user-defined data structure which is to be pointed to.
This is the mechanism for which the driver allows the RX application to control
what data to be sent for a given I2C address when a REMOTE_I2C_READ is issued
by an upstream device.
Signed-off-by: Andrei-Liviu Simion <andrei.simion@xilinx.com>
Topology contains information for responding to LINK_ADDRESS sideband messages
and I2C maps for each port for responding to REMOTE_I2C_READ.
Signed-off-by: Andrei-Liviu Simion <andrei.simion@xilinx.com>
- ReplyType: The driver already checks for NACK elsewhere.
- RequestId: The link address reply will always carry the LINK_ADDRESS tag.
Signed-off-by: Andrei-Liviu Simion <andrei.simion@xilinx.com>
Both RX and TX cases use the CRC functions so having *Tx* in the function name
is incorrect.
Signed-off-by: Andrei-Liviu Simion <andrei.simion@xilinx.com>
Larger messages will need to be split into multiple fragments.
- The MsgData member carries all information.
- The FragmentNum member indicates the last fragment processed.
- The header reflects the latest fragment.
Signed-off-by: Andrei-Liviu Simion <andrei.simion@xilinx.com>
1) Down request for MST sideband messages TX to RX.
2) Down reply for MST sideband messages from RX to TX.
Signed-off-by: Andrei-Liviu Simion <andrei.simion@xilinx.com>
The IP documentation "recommends" enabling the following:
- Issuing reset at every training iteration.
- Issuing reset at every link rate change.
- Issuing reset at start of training pattern 1.
Signed-off-by: Andrei-Liviu Simion <andrei.simion@xilinx.com>
No need for this since the handler will never be called if the interrupts are
masked in the first place.
Also, by default, nested interrupts are disabled and it is up to the user to
explicitly request nested interrupts - allow this.
The interrupt mask should already apply in hardware.
Signed-off-by: Andrei-Liviu Simion <andrei.simion@xilinx.com>
Even if link training succeeds, sometimes, the link will fall if the link is
enabled prior to the training pattern being turned off.
Signed-off-by: Andrei-Liviu Simion <andrei.simion@xilinx.com>
As required by DisplayPort compliance, the clock recovery sequence should
fail if all lanes haven't completed clock recovery on the first attempt
using the maximum voltage swing supported.
Signed-off-by: Andrei-Liviu Simion <andrei.simion@xilinx.com>
Prior to initiating a new AUX transaction, always ensure that any pending
transactions have completed.
Signed-off-by: Andrei-Liviu Simion <andrei.simion@xilinx.com>
AUX reply now makes use of the REPLY_STATUS register rather than
INTERRUPT_STATUS. It seems that INTERRUPT_STATUS may be updated before
REPLY_STATUS gets updated, resulting in a race condition.
Signed-off-by: Andrei-Liviu Simion <andrei.simion@xilinx.com>
This fix stores FSBL's ATF Handoff parameters at fixed address towards
end of OCM so that ATF can avoid conflict with its sections.
Signed-off-by: Sarat Chand Savitala <saratcha@xilinx.com>