mirror of
https://github.com/genodelabs/genode.git
synced 2024-12-25 08:21:08 +00:00
Build pci_drv for framebuffer test / fix warning
This commit is contained in:
parent
2283536b27
commit
97e4470da6
@ -2,7 +2,7 @@
|
|||||||
# Build
|
# Build
|
||||||
#
|
#
|
||||||
|
|
||||||
build { core init test/framebuffer drivers/framebuffer drivers/timer }
|
build { core init test/framebuffer drivers/framebuffer drivers/pci drivers/timer }
|
||||||
|
|
||||||
create_boot_directory
|
create_boot_directory
|
||||||
|
|
||||||
|
@ -35,14 +35,11 @@ int main()
|
|||||||
Framebuffer::Mode const fb_mode = fb.mode();
|
Framebuffer::Mode const fb_mode = fb.mode();
|
||||||
|
|
||||||
/* write pixeldata to framebuffer */
|
/* write pixeldata to framebuffer */
|
||||||
void * fb_base = env()->rm_session()->attach(fb_ds_cap);
|
void *fb_base = env()->rm_session()->attach(fb_ds_cap);
|
||||||
unsigned j;
|
unsigned const fb_size = (unsigned)(mode.width()*mode.height())/2;
|
||||||
unsigned const fb_size = (unsigned)(mode.width()*mode.height())/2;
|
for (unsigned i = 0; i < fb_size; i++)
|
||||||
for(unsigned i = 0; i < fb_size; i++)
|
*(((unsigned volatile *)fb_base) + i) = i;
|
||||||
{
|
|
||||||
*(((unsigned volatile *)fb_base) + i) = j;
|
|
||||||
j++;
|
|
||||||
}
|
|
||||||
fb.refresh(0, 0, fb_mode.width(), fb_mode.height());
|
fb.refresh(0, 0, fb_mode.width(), fb_mode.height());
|
||||||
printf("--- end ---\n");
|
printf("--- end ---\n");
|
||||||
while(1);
|
while(1);
|
||||||
|
Loading…
Reference in New Issue
Block a user