<feed xmlns='http://www.w3.org/2005/Atom'>
<title>Tianocore/edk2-platforms.git/Silicon/Broadcom/Drivers/Net, branch CodeCleanup</title>
<subtitle>EDK II sample platform branches and tags (mirror)</subtitle>
<id>https://git.radix-linux.su/Tianocore/edk2-platforms.git/atom?h=CodeCleanup</id>
<link rel='self' href='https://git.radix-linux.su/Tianocore/edk2-platforms.git/atom?h=CodeCleanup'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2-platforms.git/'/>
<updated>2024-03-11T14:15:27+00:00</updated>
<entry>
<title>Silicon/Broadcom/BcmGenetDxe: Suppress some bogus compiler warnings</title>
<updated>2024-03-11T14:15:27+00:00</updated>
<author>
<name>Jeremy Linton</name>
<email>jeremy.linton@arm.com</email>
</author>
<published>2024-01-17T21:36:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2-platforms.git/commit/?id=7911dae1e84b3e0492cb19407803c80dccdd29f5'/>
<id>urn:sha1:7911dae1e84b3e0492cb19407803c80dccdd29f5</id>
<content type='text'>
Some recent GCC revisions will throw warnings about values being used
before being initialized. But in the case where the lack of initialization
is the result of the called function returning error status the EFI_ERROR()
macro/error seems to confuse the compiler about the fact that the value
is then never used.

So, while the code appears to be fine, lets just zero the variables
anyway to make the compiler happy.

Signed-off-by: Jeremy Linton &lt;jeremy.linton@arm.com&gt;
Reviewed-by: Ard Biesheuvel &lt;ardb@kernel.org&gt;
</content>
</entry>
<entry>
<title>Silicon/Broadcom/BcmGenetDxe: Delay for linkup in transmit</title>
<updated>2021-08-16T07:21:14+00:00</updated>
<author>
<name>Jeremy Linton</name>
<email>jeremy.linton@arm.com</email>
</author>
<published>2021-05-11T22:37:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2-platforms.git/commit/?id=0ad7f6b9996da2e602488053b498096ad0077f6c'/>
<id>urn:sha1:0ad7f6b9996da2e602488053b498096ad0077f6c</id>
<content type='text'>
Under normal circumstances GenetSimpleNetworkTransmit won't be
called unless the rest of the network stack detects the link is
up. So, during normal operation when the adapter is initialized
the link naturally transitions to link up, and then is ready for
activity later in the boot sequence. If that hasn't happened by
the time PXE runs then it will itself wait for the link.

OTOH, the normal distro PXE sequence involves PXE loading shim
which in turn loads grub, which tries to read machine specific
configs, modules, and grub.cfg in order to prepare the boot menu.
Then, once a grub selection is picked, it might try to load the
kernel+initrd.

In this sequence the network stack is shutdown and restarted
multiple times. Grub though, starts up, notices its been network
booted, reads saved network parameters and immediately tries to
transmit data assuming the link is still up.

When that happens grub will print "couldn't send network packet"
and if that lasts long enough it fails to load grub.cfg and the
user gets dropped to the grub prompt because no one in the path
bothers to assure the link state has transitioned back up.

For reference: https://github.com/pftf/RPi4/issues/113

This patch fixes that by polling the link state via
GenericPhyUpdateConfig() for ten seconds in the transmit path
when the link is down. If the link recovers within this timeout
the state machine is transitioned and we continue data
transmission. If the 10 seconds expires without the link
resuming we will fail as before. While full link negotiation
can be fast, it frequently can take a second or two, or longer
depending on the remote peer on the other end of the
Ethernet cable. It seems auto MDX can slow this down,
and certain vendors products seem to be slower than the
norm. Ten seconds may not cover some of these possibilities,
but the user should validate cabling and the switch/peer's
port configuration if resuming the link is taking &gt; 10
seconds. Picking a longer timeout is a tradeoff between the
machine appearing to hang for extended periods of time
(due to grub retries) if the link is actually down vs
generally providing enough time for most endpoints to
complete the negotiation.

Signed-off-by: Jeremy Linton &lt;jeremy.linton@arm.com&gt;
Reviewed-by: Jared McNeill &lt;jmcneill@invisible.ca&gt;
Reviewed-by: Andrei Warkentin &lt;awarkentin@vmware.com&gt;
</content>
</entry>
<entry>
<title>Platforms/RaspberryPi: Fix BcmGenetDxe ComponentName2 error checking</title>
<updated>2020-08-17T13:52:32+00:00</updated>
<author>
<name>Samer El-Haj-Mahmoud</name>
<email>Samer.El-Haj-Mahmoud@arm.com</email>
</author>
<published>2020-08-15T20:26:31+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2-platforms.git/commit/?id=69009e5b91a70b6fc15cdf4bc410256052cb5752'/>
<id>urn:sha1:69009e5b91a70b6fc15cdf4bc410256052cb5752</id>
<content type='text'>
Fix input param error checking for the BcmGenetDxe ComponentName2
protocol.

This fixes https://github.com/pftf/RPi4/issues/85

Signed-off-by: Samer El-Haj-Mahmoud &lt;samer.el-haj-mahmoud@arm.com&gt;
Reviewed-by: Pete Batard &lt;pete@akeo.ie&gt;
</content>
</entry>
<entry>
<title>Silicon/BcmGenetDxe: don't consume RX buffer until it's actually copied</title>
<updated>2020-07-14T14:46:05+00:00</updated>
<author>
<name>Andrei Warkentin</name>
<email>andrey.warkentin@gmail.com</email>
</author>
<published>2020-07-12T04:28:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2-platforms.git/commit/?id=2242b990248c64d21ea830c7f30c88374b5b18a5'/>
<id>urn:sha1:2242b990248c64d21ea830c7f30c88374b5b18a5</id>
<content type='text'>
This was originally a bit sloppy, and could hypothetically under heavy
load result in a buffer being overwritten by hardware before the received
buffer is copied.

Signed-off-by: Andrei Warkentin &lt;andrey.warkentin@gmail.com&gt;
Reviewed-by: Pete Batard &lt;pete@akeo.ie&gt;
Reviewed-by: Leif Lindholm &lt;leif@nuviainc.com&gt;
</content>
</entry>
<entry>
<title>Silicon/Broadcom/BcmGenetDxe: implement media state adapter info protocol</title>
<updated>2020-06-18T10:32:06+00:00</updated>
<author>
<name>Ard Biesheuvel</name>
<email>ard.biesheuvel@arm.com</email>
</author>
<published>2020-06-16T18:08:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2-platforms.git/commit/?id=743f501b66db712d486347ddca781ffc705c1766'/>
<id>urn:sha1:743f501b66db712d486347ddca781ffc705c1766</id>
<content type='text'>
NetLibDetectMedia () in DxeNetLib is used as a fallback on implementations
of the SNP protocol that do not also carry an implementation of the adapter
info protocol to provide media state information, and it does all kinds of
terrible things to the network interface (stopping and restarting multiple
times, reprogramming the multicast filters etc etc) to workaround some
alleged UNDI shortcoming.

Although our GENET code should be bullet proof and therefore able to take
this kind of abuse, it is better to avoid it, and provide an implementation
of the adapter info protocol that returns the media state directly, without
the need to mistreat the SNP layer.

Signed-off-by: Ard Biesheuvel &lt;ard.biesheuvel@arm.com&gt;
Reviewed-by: Samer El-Haj-Mahmoud &lt;Samer.El-Haj-Mahmoud@arm.com&gt;
Tested-by: Samer El-Haj-Mahmoud &lt;Samer.El-Haj-Mahmoud@arm.com&gt;
</content>
</entry>
<entry>
<title>Silicon/Broadcom/BcmGenetDxe: program MAC also when not connected</title>
<updated>2020-06-05T08:07:45+00:00</updated>
<author>
<name>Ard Biesheuvel</name>
<email>ard.biesheuvel@arm.com</email>
</author>
<published>2020-06-04T09:19:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2-platforms.git/commit/?id=42b86f6d4e910d5f89ce75a60e630285b130cc7c'/>
<id>urn:sha1:42b86f6d4e910d5f89ce75a60e630285b130cc7c</id>
<content type='text'>
In preparation of removing the EfiBootManagerConnectAll() from the
ordinary boot path, ensure that the MAC programming of the GENET
occurs even if the SNP driver for it is never invoked by the BDS.

Signed-off-by: Ard Biesheuvel &lt;ard.biesheuvel@arm.com&gt;
Reviewed-by: Pete Batard &lt;pete@akeo.ie&gt;
Tested-by: Pete Batard &lt;pete@akeo.ie&gt;
Acked-by: Leif Lindholm &lt;leif@nuviainc.com&gt;
</content>
</entry>
<entry>
<title>Silicon/Broadcom/BcmGenetDxe: Fix reliability issues</title>
<updated>2020-05-12T22:01:11+00:00</updated>
<author>
<name>Andrei Warkentin</name>
<email>andrey.warkentin@gmail.com</email>
</author>
<published>2020-05-12T21:52:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2-platforms.git/commit/?id=3698b912301b51df5a6823669edbeba72ce05f69'/>
<id>urn:sha1:3698b912301b51df5a6823669edbeba72ce05f69</id>
<content type='text'>
TFTP and HTTP downloads were failing. The problem was that the incorrect
PROD index was being written TX ring. The PROD index should be the
TxProdIndex (in the range [0-0xffff]), not the descriptor index (in the
range [0-num descs)).

Also, mod 0xffff is not the same as &amp; 0xffff, so fix that as well.

Signed-off-by: Andrei Warkentin &lt;andrey.warkentin@gmail.com&gt;
Tested-by: Samer El-Haj-Mahmoud &lt;Samer.El-Haj-Mahmoud@arm.com&gt;
</content>
</entry>
<entry>
<title>Platform/RaspberryPi4: Clean up PCDs out of the GENET driver</title>
<updated>2020-05-12T17:19:35+00:00</updated>
<author>
<name>Ard Biesheuvel</name>
<email>ard.biesheuvel@arm.com</email>
</author>
<published>2020-05-12T07:18:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2-platforms.git/commit/?id=b26c406249e99cf6993abb8af26ec649ef4fe0e8'/>
<id>urn:sha1:b26c406249e99cf6993abb8af26ec649ef4fe0e8</id>
<content type='text'>
Move PCDs from GENET driver to Raspberry Pi and Bcm27xx packages.
The Genet driver follows the UEFI driver model, so it should not have
PCDs defined that describe MMIO and MAC addresses of a single instance.
Also, move related definitions around, and update references accordingly.

Signed-off-by: Ard Biesheuvel &lt;ard.biesheuvel@arm.com&gt;
Reviewed-by: Leif Lindholm &lt;leif@nuviainc.com&gt;
</content>
</entry>
<entry>
<title>Silicon/Broadcom/BcmGenetDxe: Add GENET driver</title>
<updated>2020-05-12T17:19:35+00:00</updated>
<author>
<name>Ard Biesheuvel</name>
<email>ard.biesheuvel@arm.com</email>
</author>
<published>2020-05-12T07:17:54+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2-platforms.git/commit/?id=8f330caf903963aadae92372b3ef0a98335c0931'/>
<id>urn:sha1:8f330caf903963aadae92372b3ef0a98335c0931</id>
<content type='text'>
Add support for the Broadcom GENET v5 ethernet controller
for the Raspberry Pi 4 (BCM2711)

Co-authored-by: Jared McNeill &lt;jmcneill@invisible.ca&gt;
Co-authored-by: Andrei Warkentin &lt;awarkentin@vmware.com&gt;
Co-authored-by: Samer El-Haj-Mahmoud &lt;samer.el-haj-mahmoud@arm.com&gt;
Co-authored-by: Ard Biesheuvel &lt;ard.biesheuvel@arm.com&gt;
Signed-off-by: Ard Biesheuvel &lt;ard.biesheuvel@arm.com&gt;
Reviewed-by: Leif Lindholm &lt;leif@nuviainc.com&gt;
</content>
</entry>
<entry>
<title>Silicon/Broadcom: Add BcmGenetPlatformDevice protocol</title>
<updated>2020-05-12T15:27:16+00:00</updated>
<author>
<name>Ard Biesheuvel</name>
<email>ard.biesheuvel@arm.com</email>
</author>
<published>2020-05-12T07:17:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2-platforms.git/commit/?id=cc2e45a85dcdc5ac2d332750854d1d82bcb4646f'/>
<id>urn:sha1:cc2e45a85dcdc5ac2d332750854d1d82bcb4646f</id>
<content type='text'>
Add BcmGenetPlatformDevice definition for GENET. This protocol
will be used to register GENET platform device that is on a
non-discoverable bus.

Signed-off-by: Ard Biesheuvel &lt;ard.biesheuvel@arm.com&gt;
Reviewed-by: Leif Lindholm &lt;leif@nuviainc.com&gt;
</content>
</entry>
</feed>
