[ipxe-devel] Apple EFI SNP set ReceiveFilters patch
Curtis Larsen
larsen at dixie.edu
Tue Aug 5 04:30:20 UTC 2014
Attached is the git diff for changes necessary to make the Apple EFI
allow SNP->ReceiveFilters to actually set SNP->RecieveFilterSetting.
Also included in the patch are a debugging routine to display the
SNP->Mode structure, a modification to snpnet_poll_rx to check if there
is something to receive, a possible typo correction in snpnet_poll_tx,
Michael Brown's change to open EFI driver protocols by GET_PROTOCOL, and
a debugging check for failed calls to DisconnectController.
The behavior seen in the Apple EFI (1.10) on SNP->RecieveFilters is:
- Failure if any of the PROMISCUOUS or MULTICAST filters are included
- Success if only UNICAST is included, however the result is UNICAST |
BROADCAST
- Success if only UNICAST and BROADCAST are included
- If UNICAST, or UNICAST|BROADCAST are used, but the previous call tried
(and failed) to set UNICAST|BROADCAST|MULTICAST, then the result is
UNICAST|BROADCAST|MULTICAST
Yes, this sounds broken to me, but it's the way it works.
So, the modified code does tries using SNP->RecieveFilterMask, then
falls back to UNICAST|BROADCAST|MULTICAST, then UNICAST|BROADCAST, and
finally UNICAST.
I'd be happy to do any further testing, or to clean up the code anyway
you'd like.
Sorry, I didn't configure my editor for tabbed spacing, so I hope you
have a pretty-printer to filter through.
Thanks,
Curtis Larsen
-------------- next part --------------
A non-text attachment was scrubbed...
Name: AppleReceiveFilters.patch
Type: text/x-patch
Size: 10598 bytes
Desc: not available
URL: <http://lists.ipxe.org/pipermail/ipxe-devel/attachments/20140804/fa46cb60/attachment.bin>
More information about the ipxe-devel
mailing list