{"action":"created","issue":{"url":"https://api.github.com/repos/bus1/bus1/issues/54","repository_url":"https://api.github.com/repos/bus1/bus1","labels_url":"https://api.github.com/repos/bus1/bus1/issues/54/labels{/name}","comments_url":"https://api.github.com/repos/bus1/bus1/issues/54/comments","events_url":"https://api.github.com/repos/bus1/bus1/issues/54/events","html_url":"https://github.com/bus1/bus1/issues/54","id":197508548,"number":54,"title":"test-io: test.h:102: test_open: Assertion `*mapp != ((void *) -1)' failed","user":{"login":"scanf","id":925044,"avatar_url":"https://avatars2.githubusercontent.com/u/925044?v=3","gravatar_id":"","url":"https://api.github.com/users/scanf","html_url":"https://github.com/scanf","followers_url":"https://api.github.com/users/scanf/followers","following_url":"https://api.github.com/users/scanf/following{/other_user}","gists_url":"https://api.github.com/users/scanf/gists{/gist_id}","starred_url":"https://api.github.com/users/scanf/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/scanf/subscriptions","organizations_url":"https://api.github.com/users/scanf/orgs","repos_url":"https://api.github.com/users/scanf/repos","events_url":"https://api.github.com/users/scanf/events{/privacy}","received_events_url":"https://api.github.com/users/scanf/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2016-12-25T17:04:51Z","updated_at":"2017-04-02T10:54:26Z","closed_at":null,"body":"`test-io` fails when run on a Raspberry. Below is the full output of `make tt`:\r\n\r\n    make[1]: Entering directory '/home/scanf/src/github.com/scanf/bus1/tools/testing/selftests/bus1'\r\n    make[1]: Nothing to be done for 'all'.\r\n    make[1]: Leaving directory '/home/scanf/src/github.com/scanf/bus1/tools/testing/selftests/bus1'\r\n    make[1]: Entering directory '/home/scanf/src/tmp/linux-rpi-4.9.y'\r\n      LD      /home/scanf/src/github.com/scanf/bus1/built-in.o\r\n      LD      /home/scanf/src/github.com/scanf/bus1/ipc/bus1/built-in.o\r\n      CC [M]  /home/scanf/src/github.com/scanf/bus1/ipc/bus1/handle.o\r\n      CC [M]  /home/scanf/src/github.com/scanf/bus1/ipc/bus1/main.o\r\n      CC [M]  /home/scanf/src/github.com/scanf/bus1/ipc/bus1/message.o\r\n      CC [M]  /home/scanf/src/github.com/scanf/bus1/ipc/bus1/peer.o\r\n      CC [M]  /home/scanf/src/github.com/scanf/bus1/ipc/bus1/tx.o\r\n      CC [M]  /home/scanf/src/github.com/scanf/bus1/ipc/bus1/user.o\r\n      CC [M]  /home/scanf/src/github.com/scanf/bus1/ipc/bus1/util.o\r\n      CC [M]  /home/scanf/src/github.com/scanf/bus1/ipc/bus1/util/active.o\r\n      CC [M]  /home/scanf/src/github.com/scanf/bus1/ipc/bus1/util/flist.o\r\n      CC [M]  /home/scanf/src/github.com/scanf/bus1/ipc/bus1/util/pool.o\r\n      CC [M]  /home/scanf/src/github.com/scanf/bus1/ipc/bus1/util/queue.o\r\n      CC [M]  /home/scanf/src/github.com/scanf/bus1/ipc/bus1/tests.o\r\n      LD [M]  /home/scanf/src/github.com/scanf/bus1/ipc/bus1/bus1.o\r\n      Building modules, stage 2.\r\n      MODPOST 1 modules\r\n      CC      /home/scanf/src/github.com/scanf/bus1/ipc/bus1/bus1.mod.o\r\n      LD [M]  /home/scanf/src/github.com/scanf/bus1/ipc/bus1/bus1.ko\r\n    make[1]: Leaving directory '/home/scanf/src/tmp/linux-rpi-4.9.y'\r\n    sudo sh -c 'dmesg -c > /dev/null'\r\n    sudo sh -c 'rmmod bus1'\r\n    sudo sh -c 'insmod ipc/bus1/bus1.ko'\r\n    make[1]: Entering directory '/home/scanf/src/github.com/scanf/bus1/tools/testing/selftests/bus1'\r\n    selftests: test-api [PASS]\r\n    UDS took 6598 ns without payload\r\n    UDS took 10542 ns\r\n    test-io: test.h:102: test_open: Assertion `*mapp != ((void *) -1)' failed.\r\n    Aborted\r\n    selftests: test-io [FAIL]\r\n    make[1]: Leaving directory '/home/scanf/src/github.com/scanf/bus1/tools/testing/selftests/bus1'\r\n    [ 1654.992491] bus1: unloaded\r\n    [ 1655.154023] bus1: run selftests..\r\n    [ 1655.156364] bus1: loaded\r\n\r\n\r\nI am not sure what is going wrong, but it looks like we can't allocate enough\r\nmemory. Applying the patch below fixes the issue and the tests pass.\r\n\r\n    diff --git a/tools/testing/selftests/bus1/test.h b/tools/testing/selftests/bus1/test.h\r\n    index fee815e1844d..c8591de6ebe0 100644\r\n    --- a/tools/testing/selftests/bus1/test.h\r\n    +++ b/tools/testing/selftests/bus1/test.h\r\n    @@ -92,7 +92,7 @@ static inline int test_parse_argv(int argc, char **argv)\r\n     \r\n     static inline int test_open(const uint8_t **mapp, size_t *n_mapp)\r\n     {\r\n    -       const size_t size = 16UL * 1024UL * 1024UL;\r\n    +       const size_t size = 16UL * 1024UL;\r\n            int fd;\r\n     \r\n            fd = open(test_path, O_RDWR | O_CLOEXEC | O_NONBLOCK | O_NOCTTY);\r\n"},"comment":{"url":"https://api.github.com/repos/bus1/bus1/issues/comments/290978820","html_url":"https://github.com/bus1/bus1/issues/54#issuecomment-290978820","issue_url":"https://api.github.com/repos/bus1/bus1/issues/54","id":290978820,"user":{"login":"dvdhrm","id":623857,"avatar_url":"https://avatars2.githubusercontent.com/u/623857?v=3","gravatar_id":"","url":"https://api.github.com/users/dvdhrm","html_url":"https://github.com/dvdhrm","followers_url":"https://api.github.com/users/dvdhrm/followers","following_url":"https://api.github.com/users/dvdhrm/following{/other_user}","gists_url":"https://api.github.com/users/dvdhrm/gists{/gist_id}","starred_url":"https://api.github.com/users/dvdhrm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dvdhrm/subscriptions","organizations_url":"https://api.github.com/users/dvdhrm/orgs","repos_url":"https://api.github.com/users/dvdhrm/repos","events_url":"https://api.github.com/users/dvdhrm/events{/privacy}","received_events_url":"https://api.github.com/users/dvdhrm/received_events","type":"User","site_admin":false},"created_at":"2017-04-02T10:54:26Z","updated_at":"2017-04-02T10:54:26Z","body":"Should be fixed in ad9014e073a0c86682f9fc322d19405b838f5b0f.\r\n\r\nThanks!"}}
{"actor":{"display_login":"dvdhrm"}}