mirror of
https://github.com/ipxe/ipxe
synced 2025-12-22 21:11:03 +03:00
Can now both send and receive packets. LL header format not yet
fixed; still using a quick hack-up just to be able to pass through data.
This commit is contained in:
@@ -70,6 +70,17 @@ static int ib_tx ( struct io_buffer *iobuf, struct net_device *netdev,
|
||||
* network-layer protocol.
|
||||
*/
|
||||
static int ib_rx ( struct io_buffer *iobuf, struct net_device *netdev ) {
|
||||
|
||||
struct {
|
||||
uint16_t proto;
|
||||
uint16_t reserved;
|
||||
} * header = iobuf->data;
|
||||
|
||||
iob_pull ( iobuf, sizeof ( *header ) );
|
||||
return net_rx ( iobuf, netdev, header->proto, NULL );
|
||||
|
||||
|
||||
|
||||
struct ibhdr *ibhdr = iobuf->data;
|
||||
|
||||
/* Sanity check */
|
||||
|
||||
Reference in New Issue
Block a user