[PATCH rtems] fat_fat_operations.c: Fix incorrect indentation
--- cpukit/libfs/src/dosfs/fat_fat_operations.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/cpukit/libfs/src/dosfs/fat_fat_operations.c b/cpukit/libfs/src/dosfs/fat_fat_operations.c index 24a408f9c7..1d94beb26a 100644 --- a/cpukit/libfs/src/dosfs/fat_fat_operations.c +++ b/cpukit/libfs/src/dosfs/fat_fat_operations.c @@ -203,9 +203,9 @@ fat_free_fat_clusters_chain( cur_cln = next_cln; } -fs_info->vol.next_cl = chain; -if (fs_info->vol.free_cls != FAT_UNDEFINED_VALUE) -fs_info->vol.free_cls += freed_cls_cnt; +fs_info->vol.next_cl = chain; +if (fs_info->vol.free_cls != FAT_UNDEFINED_VALUE) +fs_info->vol.free_cls += freed_cls_cnt; fat_buf_release(fs_info); if (rc1 != RC_OK) -- 2.31.1 ___ devel mailing list devel@rtems.org http://lists.rtems.org/mailman/listinfo/devel
Re: [PATCH rtems] fat_fat_operations.c: Fix incorrect indentation
OK Chris On 4/10/2023 2:29 am, Joel Sherrill wrote: > --- > cpukit/libfs/src/dosfs/fat_fat_operations.c | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) > > diff --git a/cpukit/libfs/src/dosfs/fat_fat_operations.c > b/cpukit/libfs/src/dosfs/fat_fat_operations.c > index 24a408f9c7..1d94beb26a 100644 > --- a/cpukit/libfs/src/dosfs/fat_fat_operations.c > +++ b/cpukit/libfs/src/dosfs/fat_fat_operations.c > @@ -203,9 +203,9 @@ fat_free_fat_clusters_chain( > cur_cln = next_cln; > } > > -fs_info->vol.next_cl = chain; > -if (fs_info->vol.free_cls != FAT_UNDEFINED_VALUE) > -fs_info->vol.free_cls += freed_cls_cnt; > +fs_info->vol.next_cl = chain; > +if (fs_info->vol.free_cls != FAT_UNDEFINED_VALUE) > +fs_info->vol.free_cls += freed_cls_cnt; > > fat_buf_release(fs_info); > if (rc1 != RC_OK) ___ devel mailing list devel@rtems.org http://lists.rtems.org/mailman/listinfo/devel
[PATCH] bsp/i386/pc686: Clean up warnings
From: Chris Johns --- bsps/i386/include/bsp/irq.h | 2 ++ bsps/i386/pc386/console/exar17d15x.c | 6 +++--- bsps/i386/pc386/console/fb_vesa_rm.c | 19 +++ bsps/i386/pc386/console/i386-stub.c | 2 +- bsps/i386/pc386/console/outch.c | 14 ++ bsps/i386/pc386/console/rtd316.c | 4 ++-- bsps/i386/pc386/console/tty_drv.c | 4 ++-- bsps/i386/pc386/console/uart_bus_pci.c| 16 bsps/i386/pc386/console/vgacons.c | 8 ++-- bsps/i386/pc386/include/bsp/rtd316.h | 4 ++-- bsps/i386/pc386/include/tm27.h| 2 +- bsps/i386/pc386/start/realmode_int.c | 9 + .../score/cpu/i386/include/rtems/score/cpu.h | 8 13 files changed, 65 insertions(+), 33 deletions(-) diff --git a/bsps/i386/include/bsp/irq.h b/bsps/i386/include/bsp/irq.h index c5ef954142..4ec25b0c5a 100644 --- a/bsps/i386/include/bsp/irq.h +++ b/bsps/i386/include/bsp/irq.h @@ -42,7 +42,9 @@ extern "C" { #include #include +#ifndef BSP_SHARED_HANDLER_SUPPORT #define BSP_SHARED_HANDLER_SUPPORT 1 +#endif #include #include diff --git a/bsps/i386/pc386/console/exar17d15x.c b/bsps/i386/pc386/console/exar17d15x.c index 1e6cb6fbeb..787e9a24d0 100644 --- a/bsps/i386/pc386/console/exar17d15x.c +++ b/bsps/i386/pc386/console/exar17d15x.c @@ -94,7 +94,7 @@ typedef struct { /* * Register Access Routines */ -static uint8_t xr17d15x_get_register(uint32_t addr, uint8_t i) +static uint8_t xr17d15x_get_register(uintptr_t addr, uint8_t i) { uint8_t val = 0; volatile uint8_t *reg = (volatile uint8_t *)(addr + i); @@ -104,7 +104,7 @@ static uint8_t xr17d15x_get_register(uint32_t addr, uint8_t i) return val; } -static void xr17d15x_set_register(uint32_t addr, uint8_t i, uint8_t val) +static void xr17d15x_set_register(uintptr_t addr, uint8_t i, uint8_t val) { volatile uint8_t *reg = (volatile uint8_t *)(addr + i); @@ -187,7 +187,7 @@ rtems_device_driver exar17d15x_initialize( printk( "Found Exar 17D15x %d at 0x%08lx IRQ %d with %d ports\n", instance, - conf[instance].base, + (uintptr_t) conf[instance].base, conf[instance].irq, conf[instance].ports ); diff --git a/bsps/i386/pc386/console/fb_vesa_rm.c b/bsps/i386/pc386/console/fb_vesa_rm.c index 3263bc262b..d14aa826d6 100644 --- a/bsps/i386/pc386/console/fb_vesa_rm.c +++ b/bsps/i386/pc386/console/fb_vesa_rm.c @@ -63,6 +63,17 @@ #define FB_VESA_NAME"FB_VESA_RM" +/* + * GCC complains that access to packed data may not be aligned and + * fair enough. The warning is: + * + * warning: taking address of packed member of 'struct ' may + * result in an unaligned pointer value [-Waddress-of-packed-member] + * + * Disable the warning. + */ +#pragma GCC diagnostic ignored "-Waddress-of-packed-member" + /** * @brief Allows to enable initialization of VESA real mode driver from * an application by setting the value of this variable to non null value in @@ -788,7 +799,7 @@ void vesa_realmode_bootup_init(void) (vbe_ret_val>>8)!=VBE_callSuccessful) { printk(FB_VESA_NAME " Cannot get mode info anymore. ax=0x%lx\n", -vbe_ret_val); + (uintptr_t) vbe_ret_val); } fb_var.xres = mib->XResolution; @@ -970,9 +981,9 @@ frame_buffer_control( { rtems_libio_ioctl_args_t *args = arg; - printk( FB_VESA_NAME " ioctl called, cmd=%" PRIx32 "\n", args->command ); -printk("fbxres %lu, fbyres %lu\n", fb_var.xres, fb_var.yres); -printk("fbbpp %lu\n", fb_var.bits_per_pixel); + printk( FB_VESA_NAME " ioctl called, cmd=%lx\n", (uintptr_t) args->command ); + printk("fbxres %d, fbyres %d\n", (int) fb_var.xres, (int) fb_var.yres); + printk("fbbpp %d\n", (int) fb_var.bits_per_pixel); switch (args->command) { diff --git a/bsps/i386/pc386/console/i386-stub.c b/bsps/i386/pc386/console/i386-stub.c index 1eff100e9e..4b237e0a34 100644 --- a/bsps/i386/pc386/console/i386-stub.c +++ b/bsps/i386/pc386/console/i386-stub.c @@ -502,7 +502,7 @@ getpacket (char *buffer) count = 0; /* now, read until a # or end of buffer is found */ - while (count < BUFMAX) + while (count < (BUFMAX - 1)) { ch = getDebugChar () & 0x7f; if (ch == '#') diff --git a/bsps/i386/pc386/console/outch.c b/bsps/i386/pc386/console/outch.c index 90ffedf250..83dbcdbcdf 100644 --- a/bsps/i386/pc386/console/outch.c +++ b/bsps/i386/pc386/console/outch.c @@ -283,7 +283,13 @@ static int escaped = 0; void _IBMPC_initVideo(void) { -unsigned char* pt = (unsigned char*) (VIDEO_MODE_ADDR); +/* + * See https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99578#c16 + */ +unsigned char* volatile pt = (unsigned char*) (VIDEO_MODE_ADDR); +unsigned short* volatile crt_base = (unsigned short*) DISPLAY_CRT_BASE_IO_ADDR; +uint8_t* volatile nb_max_row = (ui
[libbsd/6-freebsd-12 PATCH] i386/pc686: Fix kernel bus DMA for the PC686 BSP
From: Chris Johns The x86 provides it own bus space support. Use the generic bus space calls. This however requires the BUS_SPACE_MEM tag be provided for all architectures. Make the generic value match the x86 value. --- rtemsbsd/include/machine/bus.h| 9 + rtemsbsd/rtems/rtems-kernel-bus-dma.c | 6 +- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/rtemsbsd/include/machine/bus.h b/rtemsbsd/include/machine/bus.h index a0c3d63a..8a61a7d0 100644 --- a/rtemsbsd/include/machine/bus.h +++ b/rtemsbsd/include/machine/bus.h @@ -167,6 +167,15 @@ #endif /* BSP_HAS_PC_PCI */ +/* + * Provide a memory tag for the DMA bus interface + */ +#ifdef BSP_BUS_SPACE_MEM +#define BUS_SPACE_MEM BSP_BUS_SPACE_MEM +#else +#define BUS_SPACE_MEM 1 +#endif + /* * Bus address alignment. */ diff --git a/rtemsbsd/rtems/rtems-kernel-bus-dma.c b/rtemsbsd/rtems/rtems-kernel-bus-dma.c index 1d28f62c..9c9194b0 100644 --- a/rtemsbsd/rtems/rtems-kernel-bus-dma.c +++ b/rtemsbsd/rtems/rtems-kernel-bus-dma.c @@ -63,6 +63,10 @@ #include #endif +#ifdef X86_BUS_SPACE_MEM +#define BUS_SPACE_MEM X86_BUS_SPACE_MEM +#endif + /* * Convenience function for manipulating driver locks from busdma (during * busdma_swi, for example). Drivers that don't provide their own locks @@ -261,7 +265,7 @@ bus_dmamem_alloc(bus_dma_tag_t dmat, void** vaddr, int flags, unsigned char* mem = *vaddr; int len = dmat->maxsize; while (len-- > 0) { - bsp_bus_space_write_1(mem, 0); + bus_space_write_1(BUS_SPACE_MEM, mem, 0, 0); mem++; } } -- 2.37.1 ___ devel mailing list devel@rtems.org http://lists.rtems.org/mailman/listinfo/devel
[net-services PATCH] tests/ntp: Update to the new test printer header
From: Chris Johns --- testsuites/ntp01/test_main.c | 1 + 1 file changed, 1 insertion(+) diff --git a/testsuites/ntp01/test_main.c b/testsuites/ntp01/test_main.c index 6a744c8..4824192 100644 --- a/testsuites/ntp01/test_main.c +++ b/testsuites/ntp01/test_main.c @@ -38,6 +38,7 @@ #include #include #include +#include #include -- 2.37.1 ___ devel mailing list devel@rtems.org http://lists.rtems.org/mailman/listinfo/devel
Re: [net-services PATCH] tests/ntp: Update to the new test printer header
On 04.10.23 07:27, chr...@rtems.org wrote: From: Chris Johns --- testsuites/ntp01/test_main.c | 1 + 1 file changed, 1 insertion(+) diff --git a/testsuites/ntp01/test_main.c b/testsuites/ntp01/test_main.c index 6a744c8..4824192 100644 --- a/testsuites/ntp01/test_main.c +++ b/testsuites/ntp01/test_main.c @@ -38,6 +38,7 @@ #include #include #include +#include #include Thanks for fixing this. -- embedded brains GmbH Herr Sebastian HUBER Dornierstr. 4 82178 Puchheim Germany email: sebastian.hu...@embedded-brains.de phone: +49-89-18 94 741 - 16 fax: +49-89-18 94 741 - 08 Registergericht: Amtsgericht München Registernummer: HRB 157899 Vertretungsberechtigte Geschäftsführer: Peter Rasmussen, Thomas Dörfler Unsere Datenschutzerklärung finden Sie hier: https://embedded-brains.de/datenschutzerklaerung/ ___ devel mailing list devel@rtems.org http://lists.rtems.org/mailman/listinfo/devel