Browse Source

[aoe] Add support for identifying the underlying hardware device

Signed-off-by: Michael Brown <mcb30@ipxe.org>
tags/v1.20.1
Michael Brown 14 years ago
parent
commit
d068049789
1 changed files with 13 additions and 0 deletions
  1. 13
    0
      src/net/aoe.c

+ 13
- 0
src/net/aoe.c View File

36
 #include <ipxe/uri.h>
36
 #include <ipxe/uri.h>
37
 #include <ipxe/open.h>
37
 #include <ipxe/open.h>
38
 #include <ipxe/ata.h>
38
 #include <ipxe/ata.h>
39
+#include <ipxe/device.h>
39
 #include <ipxe/aoe.h>
40
 #include <ipxe/aoe.h>
40
 
41
 
41
 /** @file
42
 /** @file
772
 	xfer_window_changed ( &aoedev->ata );
773
 	xfer_window_changed ( &aoedev->ata );
773
 }
774
 }
774
 
775
 
776
+/**
777
+ * Identify device underlying AoE device
778
+ *
779
+ * @v aoedev		AoE device
780
+ * @ret device		Underlying device
781
+ */
782
+static struct device * aoedev_identify_device ( struct aoe_device *aoedev ) {
783
+	return aoedev->netdev->dev;
784
+}
785
+
775
 /**
786
 /**
776
  * Describe AoE device in an ACPI table
787
  * Describe AoE device in an ACPI table
777
  *
788
  *
807
 	INTF_OP ( xfer_window, struct aoe_device *, aoedev_window ),
818
 	INTF_OP ( xfer_window, struct aoe_device *, aoedev_window ),
808
 	INTF_OP ( intf_close, struct aoe_device *, aoedev_close ),
819
 	INTF_OP ( intf_close, struct aoe_device *, aoedev_close ),
809
 	INTF_OP ( acpi_describe, struct aoe_device *, aoedev_describe ),
820
 	INTF_OP ( acpi_describe, struct aoe_device *, aoedev_describe ),
821
+	INTF_OP ( identify_device, struct aoe_device *,
822
+		  aoedev_identify_device ),
810
 };
823
 };
811
 
824
 
812
 /** AoE device ATA interface descriptor */
825
 /** AoE device ATA interface descriptor */

Loading…
Cancel
Save