diff -urp net/e1000/e1000_main.c net/e1000/e1000_main.c
--- net/e1000/e1000_main.c	2011-08-05 06:59:21.000000000 +0200
+++ net/e1000/e1000_main.c	2012-02-21 04:23:42.439098126 +0100
@@ -222,6 +222,10 @@ static int debug = NETIF_MSG_DRV | NETIF
 module_param(debug, int, 0);
 MODULE_PARM_DESC(debug, "Debug level (0=none,...,16=all)");
 
+#if defined(CONFIG_NETMAP) || defined(CONFIG_NETMAP_MODULE)
+#include <if_e1000_netmap.h>
+#endif
+
 /**
  * e1000_get_hw_dev - return device
  * used by hardware layer to print debugging information
@@ -393,6 +397,10 @@ static void e1000_configure(struct e1000
 	e1000_configure_tx(adapter);
 	e1000_setup_rctl(adapter);
 	e1000_configure_rx(adapter);
+#ifdef DEV_NETMAP
+	if (e1000_netmap_init_buffers(adapter))
+		return;
+#endif /* DEV_NETMAP */
 	/* call E1000_DESC_UNUSED which always leaves
 	 * at least 1 descriptor unused to make sure
 	 * next_to_use != next_to_clean */
@@ -1175,6 +1183,10 @@ static int __devinit e1000_probe(struct
 	if (err)
 		goto err_register;
 
+#ifdef DEV_NETMAP
+	e1000_netmap_attach(adapter);
+#endif /* DEV_NETMAP */
+
 	/* print bus type/speed/width info */
 	e_info(probe, "(PCI%s:%dMHz:%d-bit) %pM\n",
 	       ((hw->bus_type == e1000_bus_type_pcix) ? "-X" : ""),
@@ -1246,6 +1258,10 @@ static void __devexit e1000_remove(struc
 
 	kfree(adapter->tx_ring);
 	kfree(adapter->rx_ring);
+	
+#ifdef DEV_NETMAP
+	netmap_detach(netdev);
+#endif /* DEV_NETMAP */
 
 	iounmap(hw->hw_addr);
 	if (hw->flash_address)
@@ -3559,6 +3576,10 @@ static bool e1000_clean_tx_irq(struct e1
 	unsigned int count = 0;
 	unsigned int total_tx_bytes=0, total_tx_packets=0;
 
+#ifdef DEV_NETMAP
+	if (netmap_tx_irq(netdev, 0))
+		return 1; /* cleaned ok */
+#endif /* DEV_NETMAP */
 	i = tx_ring->next_to_clean;
 	eop = tx_ring->buffer_info[i].next_to_watch;
 	eop_desc = E1000_TX_DESC(*tx_ring, eop);
@@ -3952,6 +3973,11 @@ static bool e1000_clean_rx_irq(struct e1
 	bool cleaned = false;
 	unsigned int total_rx_bytes=0, total_rx_packets=0;
 
+#ifdef DEV_NETMAP
+	ND("calling netmap_rx_irq");
+	if (netmap_rx_irq(netdev, 0, work_done))
+		return 1; /* seems to be ignored */
+#endif /* DEV_NETMAP */
 	i = rx_ring->next_to_clean;
 	rx_desc = E1000_RX_DESC(*rx_ring, i);
 	buffer_info = &rx_ring->buffer_info[i];
