{"action":"created","comment":{"url":"https://api.github.com/repos/containers/virtcontainers/pulls/comments/168494831","pull_request_review_id":96870012,"id":168494831,"diff_hunk":"@@ -0,0 +1,419 @@\n+//\n+// Copyright (c) 2018 Intel Corporation\n+//\n+// Licensed under the Apache License, Version 2.0 (the \"License\");\n+// you may not use this file except in compliance with the License.\n+// You may obtain a copy of the License at\n+//\n+//      http://www.apache.org/licenses/LICENSE-2.0\n+//\n+// Unless required by applicable law or agreed to in writing, software\n+// distributed under the License is distributed on an \"AS IS\" BASIS,\n+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n+// See the License for the specific language governing permissions and\n+// limitations under the License.\n+//\n+\n+package virtcontainers\n+\n+import (\n+\t\"encoding/hex\"\n+\t\"fmt\"\n+\t\"os\"\n+\n+\tgovmmQemu \"github.com/intel/govmm/qemu\"\n+)\n+\n+type qemuArch interface {\n+\t// runningOnVMM returns true if the system is running inside a VM\n+\trunningOnVMM(cpuInfoPath string) (bool, error)\n+\n+\t// disableNestingChecks nesting checks will be ignored\n+\tdisableNestingChecks()\n+\n+\t// getMachine returns the machine type\n+\tgetMachine() (govmmQemu.Machine, error)","path":"qemu_kvm.go","position":35,"original_position":35,"commit_id":"5d8b21fd18dc027b25cd7caa7e694b77f8dd5aed","original_commit_id":"5d8b21fd18dc027b25cd7caa7e694b77f8dd5aed","user":{"login":"devimc","id":13009432,"avatar_url":"https://avatars0.githubusercontent.com/u/13009432?v=4","gravatar_id":"","url":"https://api.github.com/users/devimc","html_url":"https://github.com/devimc","followers_url":"https://api.github.com/users/devimc/followers","following_url":"https://api.github.com/users/devimc/following{/other_user}","gists_url":"https://api.github.com/users/devimc/gists{/gist_id}","starred_url":"https://api.github.com/users/devimc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/devimc/subscriptions","organizations_url":"https://api.github.com/users/devimc/orgs","repos_url":"https://api.github.com/users/devimc/repos","events_url":"https://api.github.com/users/devimc/events{/privacy}","received_events_url":"https://api.github.com/users/devimc/received_events","type":"User","site_admin":false},"body":"ohh ok, let me rename them","created_at":"2018-02-15T14:42:13Z","updated_at":"2018-02-15T14:42:13Z","html_url":"https://github.com/containers/virtcontainers/pull/614#discussion_r168494831","pull_request_url":"https://api.github.com/repos/containers/virtcontainers/pulls/614","author_association":"COLLABORATOR","_links":{"self":{"href":"https://api.github.com/repos/containers/virtcontainers/pulls/comments/168494831"},"html":{"href":"https://github.com/containers/virtcontainers/pull/614#discussion_r168494831"},"pull_request":{"href":"https://api.github.com/repos/containers/virtcontainers/pulls/614"}},"in_reply_to_id":168440474},"pull_request":{"url":"https://api.github.com/repos/containers/virtcontainers/pulls/614","id":168382448,"html_url":"https://github.com/containers/virtcontainers/pull/614","diff_url":"https://github.com/containers/virtcontainers/pull/614.diff","patch_url":"https://github.com/containers/virtcontainers/pull/614.patch","issue_url":"https://api.github.com/repos/containers/virtcontainers/issues/614","number":614,"state":"open","locked":false,"title":"qemu: Add support for ARM","user":{"login":"devimc","id":13009432,"avatar_url":"https://avatars0.githubusercontent.com/u/13009432?v=4","gravatar_id":"","url":"https://api.github.com/users/devimc","html_url":"https://github.com/devimc","followers_url":"https://api.github.com/users/devimc/followers","following_url":"https://api.github.com/users/devimc/following{/other_user}","gists_url":"https://api.github.com/users/devimc/gists{/gist_id}","starred_url":"https://api.github.com/users/devimc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/devimc/subscriptions","organizations_url":"https://api.github.com/users/devimc/orgs","repos_url":"https://api.github.com/users/devimc/repos","events_url":"https://api.github.com/users/devimc/events{/privacy}","received_events_url":"https://api.github.com/users/devimc/received_events","type":"User","site_admin":false},"body":"This patch introduces a new interface called qemuArch that contains\r\nthe functions needed to create qemu specific architecture implementations.\r\nThis patch also includes three qemu specific architecture\r\nimplementations: qemuKVM, qemuAmd64 and qemuArm64, since all architectures\r\nuse similar qemu command lines, the base structure is qemuKVM that is an\r\nagnostic implementation to start virtual machines, qemuAmd64 and qemuArm64\r\ninherit and override (if needed) the functions of qemuKVM, therefore architecture\r\nspecific optimizations are in qemuAmd64 and qemuArm64.\r\nFor example the `appendImage` function defined by qemuKVM uses a block\r\ndevice to provide the image to the VM, qemuArm64 inherits and doesn't\r\noverwrite it, but qemuAmd64 inherits and overwites it to provide the\r\nimage throught NVDIMM and DAX.\r\n    \r\nfixes #608\r\nfixes #610\r\nfixes #611\r\nfixes #612\r\n\r\nSigned-off-by: Julio Montes <julio.montes@intel.com>","created_at":"2018-02-10T02:58:48Z","updated_at":"2018-02-15T14:42:13Z","closed_at":null,"merged_at":null,"merge_commit_sha":"3cbb7bb0c147a29e66d5ee20fddd624207cd28fe","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":832913980,"url":"https://api.github.com/repos/containers/virtcontainers/labels/WIP","name":"WIP","color":"d93f0b","default":false},{"id":550573725,"url":"https://api.github.com/repos/containers/virtcontainers/labels/do-not-merge","name":"do-not-merge","color":"b60205","default":false},{"id":832019411,"url":"https://api.github.com/repos/containers/virtcontainers/labels/review","name":"review","color":"ededed","default":false}],"milestone":null,"commits_url":"https://api.github.com/repos/containers/virtcontainers/pulls/614/commits","review_comments_url":"https://api.github.com/repos/containers/virtcontainers/pulls/614/comments","review_comment_url":"https://api.github.com/repos/containers/virtcontainers/pulls/comments{/number}","comments_url":"https://api.github.com/repos/containers/virtcontainers/issues/614/comments","statuses_url":"https://api.github.com/repos/containers/virtcontainers/statuses/5d8b21fd18dc027b25cd7caa7e694b77f8dd5aed","head":{"label":"devimc:ARM","ref":"ARM","sha":"5d8b21fd18dc027b25cd7caa7e694b77f8dd5aed","user":{"login":"devimc","id":13009432,"avatar_url":"https://avatars0.githubusercontent.com/u/13009432?v=4","gravatar_id":"","url":"https://api.github.com/users/devimc","html_url":"https://github.com/devimc","followers_url":"https://api.github.com/users/devimc/followers","following_url":"https://api.github.com/users/devimc/following{/other_user}","gists_url":"https://api.github.com/users/devimc/gists{/gist_id}","starred_url":"https://api.github.com/users/devimc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/devimc/subscriptions","organizations_url":"https://api.github.com/users/devimc/orgs","repos_url":"https://api.github.com/users/devimc/repos","events_url":"https://api.github.com/users/devimc/events{/privacy}","received_events_url":"https://api.github.com/users/devimc/received_events","type":"User","site_admin":false},"repo":{"id":80849666,"name":"virtcontainers","full_name":"devimc/virtcontainers","owner":{"login":"devimc","id":13009432,"avatar_url":"https://avatars0.githubusercontent.com/u/13009432?v=4","gravatar_id":"","url":"https://api.github.com/users/devimc","html_url":"https://github.com/devimc","followers_url":"https://api.github.com/users/devimc/followers","following_url":"https://api.github.com/users/devimc/following{/other_user}","gists_url":"https://api.github.com/users/devimc/gists{/gist_id}","starred_url":"https://api.github.com/users/devimc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/devimc/subscriptions","organizations_url":"https://api.github.com/users/devimc/orgs","repos_url":"https://api.github.com/users/devimc/repos","events_url":"https://api.github.com/users/devimc/events{/privacy}","received_events_url":"https://api.github.com/users/devimc/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/devimc/virtcontainers","description":"A Go package for building hardware virtualized container runtimes","fork":true,"url":"https://api.github.com/repos/devimc/virtcontainers","forks_url":"https://api.github.com/repos/devimc/virtcontainers/forks","keys_url":"https://api.github.com/repos/devimc/virtcontainers/keys{/key_id}","collaborators_url":"https://api.github.com/repos/devimc/virtcontainers/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/devimc/virtcontainers/teams","hooks_url":"https://api.github.com/repos/devimc/virtcontainers/hooks","issue_events_url":"https://api.github.com/repos/devimc/virtcontainers/issues/events{/number}","events_url":"https://api.github.com/repos/devimc/virtcontainers/events","assignees_url":"https://api.github.com/repos/devimc/virtcontainers/assignees{/user}","branches_url":"https://api.github.com/repos/devimc/virtcontainers/branches{/branch}","tags_url":"https://api.github.com/repos/devimc/virtcontainers/tags","blobs_url":"https://api.github.com/repos/devimc/virtcontainers/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/devimc/virtcontainers/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/devimc/virtcontainers/git/refs{/sha}","trees_url":"https://api.github.com/repos/devimc/virtcontainers/git/trees{/sha}","statuses_url":"https://api.github.com/repos/devimc/virtcontainers/statuses/{sha}","languages_url":"https://api.github.com/repos/devimc/virtcontainers/languages","stargazers_url":"https://api.github.com/repos/devimc/virtcontainers/stargazers","contributors_url":"https://api.github.com/repos/devimc/virtcontainers/contributors","subscribers_url":"https://api.github.com/repos/devimc/virtcontainers/subscribers","subscription_url":"https://api.github.com/repos/devimc/virtcontainers/subscription","commits_url":"https://api.github.com/repos/devimc/virtcontainers/commits{/sha}","git_commits_url":"https://api.github.com/repos/devimc/virtcontainers/git/commits{/sha}","comments_url":"https://api.github.com/repos/devimc/virtcontainers/comments{/number}","issue_comment_url":"https://api.github.com/repos/devimc/virtcontainers/issues/comments{/number}","contents_url":"https://api.github.com/repos/devimc/virtcontainers/contents/{+path}","compare_url":"https://api.github.com/repos/devimc/virtcontainers/compare/{base}...{head}","merges_url":"https://api.github.com/repos/devimc/virtcontainers/merges","archive_url":"https://api.github.com/repos/devimc/virtcontainers/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/devimc/virtcontainers/downloads","issues_url":"https://api.github.com/repos/devimc/virtcontainers/issues{/number}","pulls_url":"https://api.github.com/repos/devimc/virtcontainers/pulls{/number}","milestones_url":"https://api.github.com/repos/devimc/virtcontainers/milestones{/number}","notifications_url":"https://api.github.com/repos/devimc/virtcontainers/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/devimc/virtcontainers/labels{/name}","releases_url":"https://api.github.com/repos/devimc/virtcontainers/releases{/id}","deployments_url":"https://api.github.com/repos/devimc/virtcontainers/deployments","created_at":"2017-02-03T17:00:24Z","updated_at":"2017-02-03T17:00:26Z","pushed_at":"2018-02-15T01:08:41Z","git_url":"git://github.com/devimc/virtcontainers.git","ssh_url":"git@github.com:devimc/virtcontainers.git","clone_url":"https://github.com/devimc/virtcontainers.git","svn_url":"https://github.com/devimc/virtcontainers","homepage":null,"size":10886,"stargazers_count":0,"watchers_count":0,"language":"Go","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0"},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"containers:master","ref":"master","sha":"98ccd531cbc8c5b7d4a6529d1e0666815d65a278","user":{"login":"containers","id":5874934,"avatar_url":"https://avatars3.githubusercontent.com/u/5874934?v=4","gravatar_id":"","url":"https://api.github.com/users/containers","html_url":"https://github.com/containers","followers_url":"https://api.github.com/users/containers/followers","following_url":"https://api.github.com/users/containers/following{/other_user}","gists_url":"https://api.github.com/users/containers/gists{/gist_id}","starred_url":"https://api.github.com/users/containers/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/containers/subscriptions","organizations_url":"https://api.github.com/users/containers/orgs","repos_url":"https://api.github.com/users/containers/repos","events_url":"https://api.github.com/users/containers/events{/privacy}","received_events_url":"https://api.github.com/users/containers/received_events","type":"Organization","site_admin":false},"repo":{"id":71125072,"name":"virtcontainers","full_name":"containers/virtcontainers","owner":{"login":"containers","id":5874934,"avatar_url":"https://avatars3.githubusercontent.com/u/5874934?v=4","gravatar_id":"","url":"https://api.github.com/users/containers","html_url":"https://github.com/containers","followers_url":"https://api.github.com/users/containers/followers","following_url":"https://api.github.com/users/containers/following{/other_user}","gists_url":"https://api.github.com/users/containers/gists{/gist_id}","starred_url":"https://api.github.com/users/containers/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/containers/subscriptions","organizations_url":"https://api.github.com/users/containers/orgs","repos_url":"https://api.github.com/users/containers/repos","events_url":"https://api.github.com/users/containers/events{/privacy}","received_events_url":"https://api.github.com/users/containers/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/containers/virtcontainers","description":"A Go package for building hardware virtualized container runtimes","fork":false,"url":"https://api.github.com/repos/containers/virtcontainers","forks_url":"https://api.github.com/repos/containers/virtcontainers/forks","keys_url":"https://api.github.com/repos/containers/virtcontainers/keys{/key_id}","collaborators_url":"https://api.github.com/repos/containers/virtcontainers/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/containers/virtcontainers/teams","hooks_url":"https://api.github.com/repos/containers/virtcontainers/hooks","issue_events_url":"https://api.github.com/repos/containers/virtcontainers/issues/events{/number}","events_url":"https://api.github.com/repos/containers/virtcontainers/events","assignees_url":"https://api.github.com/repos/containers/virtcontainers/assignees{/user}","branches_url":"https://api.github.com/repos/containers/virtcontainers/branches{/branch}","tags_url":"https://api.github.com/repos/containers/virtcontainers/tags","blobs_url":"https://api.github.com/repos/containers/virtcontainers/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/containers/virtcontainers/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/containers/virtcontainers/git/refs{/sha}","trees_url":"https://api.github.com/repos/containers/virtcontainers/git/trees{/sha}","statuses_url":"https://api.github.com/repos/containers/virtcontainers/statuses/{sha}","languages_url":"https://api.github.com/repos/containers/virtcontainers/languages","stargazers_url":"https://api.github.com/repos/containers/virtcontainers/stargazers","contributors_url":"https://api.github.com/repos/containers/virtcontainers/contributors","subscribers_url":"https://api.github.com/repos/containers/virtcontainers/subscribers","subscription_url":"https://api.github.com/repos/containers/virtcontainers/subscription","commits_url":"https://api.github.com/repos/containers/virtcontainers/commits{/sha}","git_commits_url":"https://api.github.com/repos/containers/virtcontainers/git/commits{/sha}","comments_url":"https://api.github.com/repos/containers/virtcontainers/comments{/number}","issue_comment_url":"https://api.github.com/repos/containers/virtcontainers/issues/comments{/number}","contents_url":"https://api.github.com/repos/containers/virtcontainers/contents/{+path}","compare_url":"https://api.github.com/repos/containers/virtcontainers/compare/{base}...{head}","merges_url":"https://api.github.com/repos/containers/virtcontainers/merges","archive_url":"https://api.github.com/repos/containers/virtcontainers/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/containers/virtcontainers/downloads","issues_url":"https://api.github.com/repos/containers/virtcontainers/issues{/number}","pulls_url":"https://api.github.com/repos/containers/virtcontainers/pulls{/number}","milestones_url":"https://api.github.com/repos/containers/virtcontainers/milestones{/number}","notifications_url":"https://api.github.com/repos/containers/virtcontainers/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/containers/virtcontainers/labels{/name}","releases_url":"https://api.github.com/repos/containers/virtcontainers/releases{/id}","deployments_url":"https://api.github.com/repos/containers/virtcontainers/deployments","created_at":"2016-10-17T10:08:28Z","updated_at":"2018-02-13T20:55:38Z","pushed_at":"2018-02-15T10:05:50Z","git_url":"git://github.com/containers/virtcontainers.git","ssh_url":"git@github.com:containers/virtcontainers.git","clone_url":"https://github.com/containers/virtcontainers.git","svn_url":"https://github.com/containers/virtcontainers","homepage":null,"size":11024,"stargazers_count":78,"watchers_count":78,"language":"Go","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":26,"mirror_url":null,"archived":false,"open_issues_count":66,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0"},"forks":26,"open_issues":66,"watchers":78,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/containers/virtcontainers/pulls/614"},"html":{"href":"https://github.com/containers/virtcontainers/pull/614"},"issue":{"href":"https://api.github.com/repos/containers/virtcontainers/issues/614"},"comments":{"href":"https://api.github.com/repos/containers/virtcontainers/issues/614/comments"},"review_comments":{"href":"https://api.github.com/repos/containers/virtcontainers/pulls/614/comments"},"review_comment":{"href":"https://api.github.com/repos/containers/virtcontainers/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/containers/virtcontainers/pulls/614/commits"},"statuses":{"href":"https://api.github.com/repos/containers/virtcontainers/statuses/5d8b21fd18dc027b25cd7caa7e694b77f8dd5aed"}},"author_association":"COLLABORATOR"}}
{"actor":{"display_login":"devimc"}}