{"action":"created","comment":{"url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/pulls/comments/36282297","id":36282297,"diff_hunk":"@@ -62,17 +62,23 @@ typedef enum _sai_switch_oper_status_t\n */\n typedef enum _sai_packet_action_t\n {\n-    /* Drop Packet */\n+    /* Drop Packet in data plane */\n     SAI_PACKET_ACTION_DROP,\n \n-    /* Forward Packet */\n+    /* Forward Packet in data plane */\n     SAI_PACKET_ACTION_FORWARD,\n \n-    /* Trap Packet to CPU */\n+    /* Copy Packet to CPU. Forwarding decision will be based on the lookup results in the NPU's Pipeline */\n+    SAI_PACKET_ACTION_COPY,\n+\n+    /* Copy Packet to CPU and Drop the packet in data plane (CPU + Drop) */\n     SAI_PACKET_ACTION_TRAP,\n \n-    /* Log (Trap + Forward) Packet */\n-    SAI_PACKET_ACTION_LOG\n+    /* Copy Packet to CPU and Forward the packet in data plane (CPU + Forward) */","path":"sai/inc/saiswitch.h","position":21,"original_position":21,"commit_id":"ccbd0151b080f78f0ae8f9800ae52bbb0d9e4df5","original_commit_id":"ccbd0151b080f78f0ae8f9800ae52bbb0d9e4df5","user":{"login":"lguohan","id":2293967,"avatar_url":"https://avatars.githubusercontent.com/u/2293967?v=3","gravatar_id":"","url":"https://api.github.com/users/lguohan","html_url":"https://github.com/lguohan","followers_url":"https://api.github.com/users/lguohan/followers","following_url":"https://api.github.com/users/lguohan/following{/other_user}","gists_url":"https://api.github.com/users/lguohan/gists{/gist_id}","starred_url":"https://api.github.com/users/lguohan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lguohan/subscriptions","organizations_url":"https://api.github.com/users/lguohan/orgs","repos_url":"https://api.github.com/users/lguohan/repos","events_url":"https://api.github.com/users/lguohan/events{/privacy}","received_events_url":"https://api.github.com/users/lguohan/received_events","type":"User","site_admin":false},"body":"(CPU + Forward): This is a combination of sai packet action (COPY + FORWARD)","created_at":"2015-08-05T09:08:31Z","updated_at":"2015-08-05T09:08:31Z","html_url":"https://github.com/opencomputeproject/OCP-Networking-Project-Community-Contributions/pull/136#discussion_r36282297","pull_request_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/pulls/136","_links":{"self":{"href":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/pulls/comments/36282297"},"html":{"href":"https://github.com/opencomputeproject/OCP-Networking-Project-Community-Contributions/pull/136#discussion_r36282297"},"pull_request":{"href":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/pulls/136"}}},"pull_request":{"url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/pulls/136","id":40424709,"html_url":"https://github.com/opencomputeproject/OCP-Networking-Project-Community-Contributions/pull/136","diff_url":"https://github.com/opencomputeproject/OCP-Networking-Project-Community-Contributions/pull/136.diff","patch_url":"https://github.com/opencomputeproject/OCP-Networking-Project-Community-Contributions/pull/136.patch","issue_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/issues/136","number":136,"state":"open","locked":false,"title":"New Packet Action proposed","user":{"login":"ramangupta","id":11197048,"avatar_url":"https://avatars.githubusercontent.com/u/11197048?v=3","gravatar_id":"","url":"https://api.github.com/users/ramangupta","html_url":"https://github.com/ramangupta","followers_url":"https://api.github.com/users/ramangupta/followers","following_url":"https://api.github.com/users/ramangupta/following{/other_user}","gists_url":"https://api.github.com/users/ramangupta/gists{/gist_id}","starred_url":"https://api.github.com/users/ramangupta/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ramangupta/subscriptions","organizations_url":"https://api.github.com/users/ramangupta/orgs","repos_url":"https://api.github.com/users/ramangupta/repos","events_url":"https://api.github.com/users/ramangupta/events{/privacy}","received_events_url":"https://api.github.com/users/ramangupta/received_events","type":"User","site_admin":false},"body":"Since packet action would simply replace any existing packet action, all combinations of packet actions which are non-conflicting should be supported. A new packet action is introduced which would simply copy the packet to CPU without adding any further action such as drop and forward. This would provide flexibility to user to decide on which action to use. \r\n\r\nDifferent flavors of packet action to punt a packet to CPU are:\r\nCOPY - Just send copy of packet to CPU. Drop/Forward will be based on the lookup results in the pipeline. \r\nTRAP - Copy sent to CPU and explicitly adding drop. Drop will supersede and will override the lookup result.   \r\nLOG - Copy sent to CPU and explicitly adding forward. Forward will supersede and will override the lookup result.   ","created_at":"2015-07-21T05:52:57Z","updated_at":"2015-08-05T09:08:31Z","closed_at":null,"merged_at":null,"merge_commit_sha":"61ce016e2be39e02e52672c97649a81d5def5b41","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/pulls/136/commits","review_comments_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/pulls/136/comments","review_comment_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/pulls/comments{/number}","comments_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/issues/136/comments","statuses_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/statuses/ccbd0151b080f78f0ae8f9800ae52bbb0d9e4df5","head":{"label":"ramangupta:master","ref":"master","sha":"ccbd0151b080f78f0ae8f9800ae52bbb0d9e4df5","user":{"login":"ramangupta","id":11197048,"avatar_url":"https://avatars.githubusercontent.com/u/11197048?v=3","gravatar_id":"","url":"https://api.github.com/users/ramangupta","html_url":"https://github.com/ramangupta","followers_url":"https://api.github.com/users/ramangupta/followers","following_url":"https://api.github.com/users/ramangupta/following{/other_user}","gists_url":"https://api.github.com/users/ramangupta/gists{/gist_id}","starred_url":"https://api.github.com/users/ramangupta/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ramangupta/subscriptions","organizations_url":"https://api.github.com/users/ramangupta/orgs","repos_url":"https://api.github.com/users/ramangupta/repos","events_url":"https://api.github.com/users/ramangupta/events{/privacy}","received_events_url":"https://api.github.com/users/ramangupta/received_events","type":"User","site_admin":false},"repo":{"id":38742853,"name":"OCP-Networking-Project-Community-Contributions","full_name":"ramangupta/OCP-Networking-Project-Community-Contributions","owner":{"login":"ramangupta","id":11197048,"avatar_url":"https://avatars.githubusercontent.com/u/11197048?v=3","gravatar_id":"","url":"https://api.github.com/users/ramangupta","html_url":"https://github.com/ramangupta","followers_url":"https://api.github.com/users/ramangupta/followers","following_url":"https://api.github.com/users/ramangupta/following{/other_user}","gists_url":"https://api.github.com/users/ramangupta/gists{/gist_id}","starred_url":"https://api.github.com/users/ramangupta/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ramangupta/subscriptions","organizations_url":"https://api.github.com/users/ramangupta/orgs","repos_url":"https://api.github.com/users/ramangupta/repos","events_url":"https://api.github.com/users/ramangupta/events{/privacy}","received_events_url":"https://api.github.com/users/ramangupta/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/ramangupta/OCP-Networking-Project-Community-Contributions","description":"WARNING: This repository will hold software contributions that are being worked on collaboratively by the OCP Networking Community. Code in this repository has not yet been approved and accepted by the OCP Incubation Committee.  Software in this repository should be not be used on production machines and should be treated as you would any Alpha/Beta release or any software that is in development.","fork":true,"url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions","forks_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/forks","keys_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/teams","hooks_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/hooks","issue_events_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/issues/events{/number}","events_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/events","assignees_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/assignees{/user}","branches_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/branches{/branch}","tags_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/tags","blobs_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/git/refs{/sha}","trees_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/statuses/{sha}","languages_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/languages","stargazers_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/stargazers","contributors_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/contributors","subscribers_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/subscribers","subscription_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/subscription","commits_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/commits{/sha}","git_commits_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/git/commits{/sha}","comments_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/comments{/number}","issue_comment_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/issues/comments{/number}","contents_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/contents/{+path}","compare_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/merges","archive_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/downloads","issues_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/issues{/number}","pulls_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/pulls{/number}","milestones_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/milestones{/number}","notifications_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/labels{/name}","releases_url":"https://api.github.com/repos/ramangupta/OCP-Networking-Project-Community-Contributions/releases{/id}","created_at":"2015-07-08T08:51:06Z","updated_at":"2015-07-08T08:51:06Z","pushed_at":"2015-07-29T16:12:16Z","git_url":"git://github.com/ramangupta/OCP-Networking-Project-Community-Contributions.git","ssh_url":"git@github.com:ramangupta/OCP-Networking-Project-Community-Contributions.git","clone_url":"https://github.com/ramangupta/OCP-Networking-Project-Community-Contributions.git","svn_url":"https://github.com/ramangupta/OCP-Networking-Project-Community-Contributions","homepage":"","size":6270,"stargazers_count":0,"watchers_count":0,"language":"C","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"opencomputeproject:master","ref":"master","sha":"6d4c3383bacf2582bce203618d10df2cea04340c","user":{"login":"opencomputeproject","id":4722382,"avatar_url":"https://avatars.githubusercontent.com/u/4722382?v=3","gravatar_id":"","url":"https://api.github.com/users/opencomputeproject","html_url":"https://github.com/opencomputeproject","followers_url":"https://api.github.com/users/opencomputeproject/followers","following_url":"https://api.github.com/users/opencomputeproject/following{/other_user}","gists_url":"https://api.github.com/users/opencomputeproject/gists{/gist_id}","starred_url":"https://api.github.com/users/opencomputeproject/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/opencomputeproject/subscriptions","organizations_url":"https://api.github.com/users/opencomputeproject/orgs","repos_url":"https://api.github.com/users/opencomputeproject/repos","events_url":"https://api.github.com/users/opencomputeproject/events{/privacy}","received_events_url":"https://api.github.com/users/opencomputeproject/received_events","type":"User","site_admin":false},"repo":{"id":27199774,"name":"OCP-Networking-Project-Community-Contributions","full_name":"opencomputeproject/OCP-Networking-Project-Community-Contributions","owner":{"login":"opencomputeproject","id":4722382,"avatar_url":"https://avatars.githubusercontent.com/u/4722382?v=3","gravatar_id":"","url":"https://api.github.com/users/opencomputeproject","html_url":"https://github.com/opencomputeproject","followers_url":"https://api.github.com/users/opencomputeproject/followers","following_url":"https://api.github.com/users/opencomputeproject/following{/other_user}","gists_url":"https://api.github.com/users/opencomputeproject/gists{/gist_id}","starred_url":"https://api.github.com/users/opencomputeproject/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/opencomputeproject/subscriptions","organizations_url":"https://api.github.com/users/opencomputeproject/orgs","repos_url":"https://api.github.com/users/opencomputeproject/repos","events_url":"https://api.github.com/users/opencomputeproject/events{/privacy}","received_events_url":"https://api.github.com/users/opencomputeproject/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/opencomputeproject/OCP-Networking-Project-Community-Contributions","description":"WARNING: This repository will hold software contributions that are being worked on collaboratively by the OCP Networking Community. Code in this repository has not yet been approved and accepted by the OCP Incubation Committee.  Software in this repository should be not be used on production machines and should be treated as you would any Alpha/Beta release or any software that is in development.","fork":false,"url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions","forks_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/forks","keys_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/keys{/key_id}","collaborators_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/teams","hooks_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/hooks","issue_events_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/issues/events{/number}","events_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/events","assignees_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/assignees{/user}","branches_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/branches{/branch}","tags_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/tags","blobs_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/git/refs{/sha}","trees_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/git/trees{/sha}","statuses_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/statuses/{sha}","languages_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/languages","stargazers_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/stargazers","contributors_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/contributors","subscribers_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/subscribers","subscription_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/subscription","commits_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/commits{/sha}","git_commits_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/git/commits{/sha}","comments_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/comments{/number}","issue_comment_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/issues/comments{/number}","contents_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/contents/{+path}","compare_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/compare/{base}...{head}","merges_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/merges","archive_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/downloads","issues_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/issues{/number}","pulls_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/pulls{/number}","milestones_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/milestones{/number}","notifications_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/labels{/name}","releases_url":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/releases{/id}","created_at":"2014-11-26T22:53:43Z","updated_at":"2015-07-30T11:21:12Z","pushed_at":"2015-08-05T08:39:10Z","git_url":"git://github.com/opencomputeproject/OCP-Networking-Project-Community-Contributions.git","ssh_url":"git@github.com:opencomputeproject/OCP-Networking-Project-Community-Contributions.git","clone_url":"https://github.com/opencomputeproject/OCP-Networking-Project-Community-Contributions.git","svn_url":"https://github.com/opencomputeproject/OCP-Networking-Project-Community-Contributions","homepage":"","size":9782,"stargazers_count":21,"watchers_count":21,"language":"C","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":39,"mirror_url":null,"open_issues_count":24,"forks":39,"open_issues":24,"watchers":21,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/pulls/136"},"html":{"href":"https://github.com/opencomputeproject/OCP-Networking-Project-Community-Contributions/pull/136"},"issue":{"href":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/issues/136"},"comments":{"href":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/issues/136/comments"},"review_comments":{"href":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/pulls/136/comments"},"review_comment":{"href":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/pulls/136/commits"},"statuses":{"href":"https://api.github.com/repos/opencomputeproject/OCP-Networking-Project-Community-Contributions/statuses/ccbd0151b080f78f0ae8f9800ae52bbb0d9e4df5"}}}}