Quantcast
Channel: Forum - Recent Threads
Viewing all articles
Browse latest Browse all 1583

RE: RZA1 RSK Change /dev/fb0 to 320x240

$
0
0

Hi Chris, I am using the xipImage and I made the changes you suggested, but I get the same kernel crash when I 'cat /dev/urandom > /dev/fb1'. It seems to work before the crash because I get the random data written to fb1.

I've fixed the stride and made sure everything was 16bbp as shown below. Do you have any other suggestions? I appreciate the help - thanks.

//#if 1 /* FLOATING LAYER SAMPLE */

/* Graphics 3 - Image Synthesizer */

/* Creates a 200x200 32-bit ARGB floating layer */

//#if XIP_KERNEL_WITHOUT_EXTERNAL_RAM

//uint8_t gr3_fb[ 320*240*4 ] __attribute__ ((aligned (PAGE_SIZE)));

//#else

#define gr3_fb 0x60600000 /* hard coded */

//#endif

//#endif

#if 1 /* FLOATING LAYER SAMPLE */

/* Graphics 3 - Image Synthesizer */

/* Creates a 320x240 16-bit ARGB floating layer */

[3].xres = 320,

[3].yres = 240,

[3].x_offset = 100,

[3].y_offset = 100,

[3].format = GR_FORMAT(GR_FORMAT_RGB565) | GR_RDSWA(6),

[3].bpp = 16,

[3].base = (u32)gr3_fb,

[3].blend = 1,

#endif

#if 1 /* FLOATING LAYER SAMPLE */

/* Graphics 3 - Image Synthesizer */

/* Map our floating layer as /dev/fb1 */

 #ifndef CONFIG_FB_SIMPLE

   #error Requires CONFIG_FB_SIMPLE=y

 #endif

/* simple-framebuffer */

static const struct resource simplefb_resources[] __initconst = {

DEFINE_RES_MEM_NAMED(gr3_fb, 320*240*2, "vdc5_alpha.0: fb"),

};

static const struct simplefb_platform_data simplefb_pdata = {

.width = 320,

.height = 240,

.stride = 320 * 2,

.format = "r8g8b8",

};

static const struct platform_device_info simplefb_info __initconst = {

.parent = &platform_bus,

.name = "simple-framebuffer",

.id = -1,

.res = simplefb_resources,

.num_res = ARRAY_SIZE(simplefb_resources),

.data = &simplefb_pdata,

.size_data = sizeof(simplefb_pdata),

};

#endif /* FLOATING LAYER SAMPLE */


Viewing all articles
Browse latest Browse all 1583

Trending Articles