diff --git a/src/vnet/pg/cli.c b/src/vnet/pg/cli.c
index 9da0f8d..e57e725 100644
--- a/src/vnet/pg/cli.c
+++ b/src/vnet/pg/cli.c
@@ -333,6 +333,23 @@
   return 0;
 }
 
+const char *
+pg_interface_get_input_node (pg_interface_t *pi)
+{
+  switch (pi->mode)
+    {
+    case PG_MODE_ETHERNET:
+      return ("ethernet-input");
+    case PG_MODE_IP4:
+      return ("ip4-input");
+    case PG_MODE_IP6:
+      return ("ip6-input");
+    }
+
+  ASSERT (0);
+  return ("ethernet-input");
+}
+
 static clib_error_t *
 new_stream (vlib_main_t * vm,
 	    unformat_input_t * input, vlib_cli_command_t * cmd)
@@ -351,7 +368,7 @@
   s.node_index = ~0;
   s.max_packet_bytes = s.min_packet_bytes = 64;
   s.buffer_bytes = vlib_buffer_get_default_data_size (vm);
-  s.if_id = 0;
+  s.if_id = ~0;
   s.n_max_frame = VLIB_FRAME_SIZE;
   pcap_file_name = 0;
 
@@ -427,8 +444,15 @@
     {
       if (pcap_file_name != 0)
 	{
-	  vlib_node_t *n =
-	    vlib_get_node_by_name (vm, (u8 *) "ethernet-input");
+	  vlib_node_t *n;
+
+	  ASSERT (s.if_id != ~0);
+
+	  if (s.if_id != ~0)
+	    n = vlib_get_node_by_name (vm, (u8 *) pg_interface_get_input_node (
+					     &pg->interfaces[s.if_id]));
+	  else
+	    n = vlib_get_node_by_name (vm, (u8 *) "ethernet-input");
 	  s.node_index = n->index;
 	}
       else
@@ -694,8 +718,8 @@
 	}
     }
 
-  pg_interface_add_or_get (pg, if_id, gso_enabled, gso_size,
-			   coalesce_enabled);
+  pg_interface_add_or_get (pg, if_id, gso_enabled, gso_size, coalesce_enabled,
+			   PG_MODE_ETHERNET);
 
 done:
   unformat_free (line_input);
diff --git a/src/vnet/pg/pg.api b/src/vnet/pg/pg.api
index 3a44f1d..3630e0c 100644
--- a/src/vnet/pg/pg.api
+++ b/src/vnet/pg/pg.api
@@ -22,6 +22,13 @@
 
 import "vnet/interface_types.api";
 
+enum pg_interface_mode : u8
+{
+ PG_API_MODE_ETHERNET = 0,
+ PG_API_MODE_IP4,
+ PG_API_MODE_IP6,
+};
+
 /** \brief PacketGenerator create interface request
     @param client_index - opaque cookie to identify the sender
     @param context - sender context, to match reply w/ request
@@ -37,6 +44,15 @@
   bool gso_enabled;
   u32 gso_size;
 };
+define pg_create_interface_v2
+{
+  u32 client_index;
+  u32 context;
+  vl_api_interface_index_t interface_id;
+  bool gso_enabled;
+  u32 gso_size;
+  vl_api_pg_interface_mode_t mode;
+};
 
 /** \brief PacketGenerator create interface response
     @param context - sender context, to match reply w/ request
@@ -48,6 +64,12 @@
   i32 retval;
   vl_api_interface_index_t sw_if_index;
 };
+define pg_create_interface_v2_reply
+{
+  u32 context;
+  i32 retval;
+  vl_api_interface_index_t sw_if_index;
+};
 
 /** \brief PacketGenerator interface enable/disable packet coalesce
     @param client_index - opaque cookie to identify the sender
diff --git a/src/vnet/pg/pg.h b/src/vnet/pg/pg.h
index da5af25..ffa2f8a 100644
--- a/src/vnet/pg/pg.h
+++ b/src/vnet/pg/pg.h
@@ -299,6 +299,13 @@
   _vec_len (s->edit_groups) = i;
 }
 
+typedef enum pg_interface_mode_t_
+{
+  PG_MODE_ETHERNET,
+  PG_MODE_IP4,
+  PG_MODE_IP6,
+} pg_interface_mode_t;
+
 typedef struct
 {
   /* TX lock */
@@ -316,6 +323,7 @@
   u32 gso_size;
   pcap_main_t pcap_main;
   char *pcap_file_name;
+  pg_interface_mode_t mode;
 
   mac_address_t *allowed_mcast_macs;
 } pg_interface_t;
@@ -373,9 +381,9 @@
 					   u32 tx_node_index);
 
 /* Find/create free packet-generator interface index. */
-u32 pg_interface_add_or_get (pg_main_t * pg, uword stream_index,
-			     u8 gso_enabled, u32 gso_size,
-			     u8 coalesce_enabled);
+u32 pg_interface_add_or_get (pg_main_t *pg, uword stream_index, u8 gso_enabled,
+			     u32 gso_size, u8 coalesce_enabled,
+			     pg_interface_mode_t mode);
 
 always_inline pg_node_t *
 pg_get_node (uword node_index)
diff --git a/src/vnet/pg/pg_api.c b/src/vnet/pg/pg_api.c
index 554e8ea..b3eb315 100644
--- a/src/vnet/pg/pg_api.c
+++ b/src/vnet/pg/pg_api.c
@@ -40,12 +40,13 @@
 
 #include <vlibapi/api_helper_macros.h>
 
-
-#define foreach_pg_api_msg                                              \
-_(PG_CREATE_INTERFACE, pg_create_interface)                             \
-_(PG_CAPTURE, pg_capture)                                               \
-_(PG_ENABLE_DISABLE, pg_enable_disable)                                 \
-_(PG_INTERFACE_ENABLE_DISABLE_COALESCE, pg_interface_enable_disable_coalesce)
+#define foreach_pg_api_msg                                                    \
+  _ (PG_CREATE_INTERFACE, pg_create_interface)                                \
+  _ (PG_CREATE_INTERFACE_V2, pg_create_interface_v2)                          \
+  _ (PG_CAPTURE, pg_capture)                                                  \
+  _ (PG_ENABLE_DISABLE, pg_enable_disable)                                    \
+  _ (PG_INTERFACE_ENABLE_DISABLE_COALESCE,                                    \
+     pg_interface_enable_disable_coalesce)
 
 static void
 vl_api_pg_create_interface_t_handler (vl_api_pg_create_interface_t * mp)
@@ -54,9 +55,9 @@
   int rv = 0;
 
   pg_main_t *pg = &pg_main;
-  u32 pg_if_id = pg_interface_add_or_get (pg, ntohl (mp->interface_id),
-					  mp->gso_enabled,
-					  ntohl (mp->gso_size), 0);
+  u32 pg_if_id =
+    pg_interface_add_or_get (pg, ntohl (mp->interface_id), mp->gso_enabled,
+			     ntohl (mp->gso_size), 0, PG_MODE_ETHERNET);
   pg_interface_t *pi = pool_elt_at_index (pg->interfaces, pg_if_id);
 
   /* *INDENT-OFF* */
@@ -68,6 +69,22 @@
 }
 
 static void
+vl_api_pg_create_interface_v2_t_handler (vl_api_pg_create_interface_v2_t *mp)
+{
+  vl_api_pg_create_interface_v2_reply_t *rmp;
+  int rv = 0;
+
+  pg_main_t *pg = &pg_main;
+  u32 pg_if_id =
+    pg_interface_add_or_get (pg, ntohl (mp->interface_id), mp->gso_enabled,
+			     ntohl (mp->gso_size), 0, (u8) mp->mode);
+  pg_interface_t *pi = pool_elt_at_index (pg->interfaces, pg_if_id);
+
+  REPLY_MACRO2 (VL_API_PG_CREATE_INTERFACE_V2_REPLY,
+		({ rmp->sw_if_index = ntohl (pi->sw_if_index); }));
+}
+
+static void
   vl_api_pg_interface_enable_disable_coalesce_t_handler
   (vl_api_pg_interface_enable_disable_coalesce_t * mp)
 {
diff --git a/src/vnet/pg/stream.c b/src/vnet/pg/stream.c
index 0ce640b..686627b 100644
--- a/src/vnet/pg/stream.c
+++ b/src/vnet/pg/stream.c
@@ -229,9 +229,29 @@
     }
 }
 
+u8 *
+format_pg_tun_tx_trace (u8 *s, va_list *args)
+{
+  CLIB_UNUSED (vlib_main_t * vm) = va_arg (*args, vlib_main_t *);
+  CLIB_UNUSED (vlib_node_t * node) = va_arg (*args, vlib_node_t *);
+
+  s = format (s, "PG: tunnel (no-encap)");
+  return s;
+}
+
+VNET_HW_INTERFACE_CLASS (pg_tun_hw_interface_class) = {
+  .name = "PG-tun",
+  //.format_header = format_gre_header_with_length,
+  //.unformat_header = unformat_gre_header,
+  .build_rewrite = NULL,
+  //.update_adjacency = gre_update_adj,
+  .flags = VNET_HW_INTERFACE_CLASS_FLAG_P2P,
+};
+
 u32
-pg_interface_add_or_get (pg_main_t * pg, uword if_id, u8 gso_enabled,
-			 u32 gso_size, u8 coalesce_enabled)
+pg_interface_add_or_get (pg_main_t *pg, uword if_id, u8 gso_enabled,
+			 u32 gso_size, u8 coalesce_enabled,
+			 pg_interface_mode_t mode)
 {
   vnet_main_t *vnm = vnet_get_main ();
   vlib_main_t *vm = vlib_get_main ();
@@ -262,8 +282,20 @@
       hw_addr[1] = 0xfe;
 
       pi->id = if_id;
-      ethernet_register_interface (vnm, pg_dev_class.index, i, hw_addr,
-				   &pi->hw_if_index, pg_eth_flag_change);
+      pi->mode = mode;
+
+      switch (pi->mode)
+	{
+	case PG_MODE_ETHERNET:
+	  ethernet_register_interface (vnm, pg_dev_class.index, i, hw_addr,
+				       &pi->hw_if_index, pg_eth_flag_change);
+	  break;
+	case PG_MODE_IP4:
+	case PG_MODE_IP6:
+	  pi->hw_if_index = vnet_register_interface (
+	    vnm, pg_dev_class.index, i, pg_tun_hw_interface_class.index, i);
+	  break;
+	}
       hi = vnet_get_hw_interface (vnm, pi->hw_if_index);
       if (gso_enabled)
 	{
@@ -510,9 +542,9 @@
   }
 
   /* Find an interface to use. */
-  s->pg_if_index =
-    pg_interface_add_or_get (pg, s->if_id, 0 /* gso_enabled */ ,
-			     0 /* gso_size */ , 0 /* coalesce_enabled */ );
+  s->pg_if_index = pg_interface_add_or_get (
+    pg, s->if_id, 0 /* gso_enabled */, 0 /* gso_size */,
+    0 /* coalesce_enabled */, PG_MODE_ETHERNET);
 
   if (s->sw_if_index[VLIB_RX] == ~0)
     {
