{"action":"created","issue":{"url":"https://api.github.com/repos/chaos4ever/chaos/issues/9","labels_url":"https://api.github.com/repos/chaos4ever/chaos/issues/9/labels{/name}","comments_url":"https://api.github.com/repos/chaos4ever/chaos/issues/9/comments","events_url":"https://api.github.com/repos/chaos4ever/chaos/issues/9/events","html_url":"https://github.com/chaos4ever/chaos/issues/9","id":57978203,"number":9,"title":"Make it possible to start the vga server again","user":{"login":"perlun","id":630613,"avatar_url":"https://avatars.githubusercontent.com/u/630613?v=3","gravatar_id":"","url":"https://api.github.com/users/perlun","html_url":"https://github.com/perlun","followers_url":"https://api.github.com/users/perlun/followers","following_url":"https://api.github.com/users/perlun/following{/other_user}","gists_url":"https://api.github.com/users/perlun/gists{/gist_id}","starred_url":"https://api.github.com/users/perlun/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/perlun/subscriptions","organizations_url":"https://api.github.com/users/perlun/orgs","repos_url":"https://api.github.com/users/perlun/repos","events_url":"https://api.github.com/users/perlun/events{/privacy}","received_events_url":"https://api.github.com/users/perlun/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-02-17T20:34:10Z","updated_at":"2015-02-20T20:39:45Z","closed_at":null,"body":"Right now, there is a problem that causes an exception when starting the VGA server:\r\n\r\n![image](https://cloud.githubusercontent.com/assets/630613/6236612/a812924e-b6f4-11e4-94b8-076c7ec00577.png)\r\n\r\nThis problem is believed to be caused by \"something\" overwriting memory. The correct values for the `.text` and `.data` segments should be these:\r\n\r\n```\r\nvagrant@packer-debian-7:/vagrant$ objdump -h servers/video/vga/vga\r\n\r\nservers/video/vga/vga:     file format elf32-i386\r\n\r\nSections:\r\nIdx Name          Size      VMA       LMA       File off  Algn\r\n[...]\r\n  5 .text         00001ddc  40001000  40001000  00001000  2**4\r\n                  CONTENTS, ALLOC, LOAD, READONLY, CODE\r\n  8 .data         00000c0c  40004000  40004000  00004000  2**5\r\n                  CONTENTS, ALLOC, LOAD, DATA\r\n```\r\n\r\nAs can be seen here, the VMA and LMA addresses are very nicely page-aligned. Find out why this is not the case when booting up. Is something corrupting memory (probably global memory allocation), or is there something else being fishy here?"},"comment":{"url":"https://api.github.com/repos/chaos4ever/chaos/issues/comments/75315205","html_url":"https://github.com/chaos4ever/chaos/issues/9#issuecomment-75315205","issue_url":"https://api.github.com/repos/chaos4ever/chaos/issues/9","id":75315205,"user":{"login":"perlun","id":630613,"avatar_url":"https://avatars.githubusercontent.com/u/630613?v=3","gravatar_id":"","url":"https://api.github.com/users/perlun","html_url":"https://github.com/perlun","followers_url":"https://api.github.com/users/perlun/followers","following_url":"https://api.github.com/users/perlun/following{/other_user}","gists_url":"https://api.github.com/users/perlun/gists{/gist_id}","starred_url":"https://api.github.com/users/perlun/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/perlun/subscriptions","organizations_url":"https://api.github.com/users/perlun/orgs","repos_url":"https://api.github.com/users/perlun/repos","events_url":"https://api.github.com/users/perlun/events{/privacy}","received_events_url":"https://api.github.com/users/perlun/received_events","type":"User","site_admin":false},"created_at":"2015-02-20T20:39:45Z","updated_at":"2015-02-20T20:39:45Z","body":"Alright, I think I know what the problem is now... Here is another dump:\r\n\r\n```\r\nservers/system/console/console:     file format elf32-i386\r\n\r\nSections:\r\nIdx Name          Size      VMA       LMA       File off  Algn\r\n  5 .text         00002990  40001000  40001000  00001000  2**4\r\n                  CONTENTS, ALLOC, LOAD, READONLY, CODE\r\n  6 .text.startup 000000a7  40003990  40003990  00003990  2**4\r\n                  CONTENTS, ALLOC, LOAD, READONLY, CODE\r\n  7 .data         00000808  40004000  40004000  00004000  2**5\r\n                  CONTENTS, ALLOC, LOAD, DATA\r\n```\r\n\r\n...i.e. there are two code sections. This is not supported by our (rather primitive, to be honest) ELF loader. So let's see if we can find a way to make GNU ld emit binaries that are more compliant to our subset of the ELF standard. For now, I've added better error handling in the kernel for these scenarios so we can more easily spot them if we run into them in the future."}}