Commit Graph

32553 Commits

Author SHA1 Message Date
Joel Sherrill
34e959fa86 gen68340/include/m340timer.h: Fix not a prototype warnings 2018-08-29 12:52:10 -05:00
Joel Sherrill
76ac42ff9a lpc32xx/include/bsp.h: Resolve set but not used warning 2018-08-29 12:52:10 -05:00
Joel Sherrill
350b07a036 monlib.[ch]: Fix warnings for external vs internal use of .h 2018-08-29 12:52:10 -05:00
Joel Sherrill
60702abaf2 qoriq/include/tm27.h: Fix warnings 2018-08-29 12:52:09 -05:00
Joel Sherrill
126a4544cc gen5200/include/tm27.h: Fix warnings 2018-08-29 12:52:09 -05:00
Joel Sherrill
c80f5afcb3 mpc55xxevb/clock/clock-config.c: Remove unused mpc55xx_clock_cleanup() method 2018-08-29 12:52:09 -05:00
Joel Sherrill
76b3f8c3f0 gen5200/include/bsp/bestcomm.h: Fix unused variable warning 2018-08-29 12:52:09 -05:00
Joel Sherrill
bb6eeabf8d bsps/i386/shared/cache/cache.c: Fix warnings 2018-08-29 12:52:08 -05:00
Joel Sherrill
c2e8ed6c81 gdbarmsim/include/bsp.h: Fix warnings 2018-08-29 12:52:08 -05:00
Joel Sherrill
14a218fd20 cpukit/telnetd/pty.c: Fix format overflow warning on sprintf()
cpukit/telnetd/pty.c:436:47: warning: '%X' directive writing between
   1 and 8 bytes into a region of size 3 [-Wformat-overflow=]

The devname area was malloc'ed. Now it is statically allocated and
sufficiently large to account for the potential buffer overflow.
2018-08-29 12:52:08 -05:00
Joel Sherrill
cba349cf30 bsps/m68k/shared/cache/cache.h: Fix warnings and clean up 2018-08-29 12:52:08 -05:00
Sebastian Huber
9e8bba5650 score: Remove redundant #ifdef RTEMS_SMP 2018-08-29 07:53:25 +02:00
Sebastian Huber
a6fca762b6 bsp/qoriq: Remove README
Update #2854.
2018-08-29 07:46:54 +02:00
Sebastian Huber
6d70a11905 Include <stdbool.h> in <machine/_kernel_types.h>
The FreeBSD kernel started to use the bool type.

Update #3472.
2018-08-27 07:38:54 +02:00
Sebastian Huber
27c89d7981 Add FreeBSD kernel space header files
Move the kernel space content of some Newlib provided header files to
RTEMS and libbsd.  This allows to use the Newlib provided header files
with different FreeBSD baselines.

Update #3472.
2018-08-27 07:38:54 +02:00
Daniel Hellstrom
97d2c44332 spglobalcon01: LLVM optimization makes variable i always 1
Declare i volatile to avoid compiler optimization putting i
into data section with initialization value 1.
2018-08-24 15:51:39 +02:00
Daniel Hellstrom
655108e416 psxfile01: floating point context required when calling fprintf
This avoids an exception (FP disabled) when RTEMS/Newlib have
been built with LLVM/Sparc.
2018-08-24 15:51:39 +02:00
Daniel Hellstrom
26c3f9f576 psx13: floating point context required when calling fprintf
This avoids an exception (FP disabled) when RTEMS/Newlib have
been built with LLVM/Sparc.
2018-08-24 15:51:39 +02:00
Daniel Hellstrom
0d51b6d87e capture: prevent unaligned access when reading time
LLVM warns about this:
 cpukit/libmisc/capture/capture.c:405:30: warning:
      taking address of packed member 'time' of class or structure
      'rtems_capture_record' may result in an unaligned pointer value
      [-Waddress-of-packed-member]
    rtems_capture_get_time (&in.time);

And on sparc it generates an unaligned trap which makes smpcapture01
and smpcapture02 test to fail on sparc.
2018-08-24 15:51:39 +02:00
Daniel Hellstrom
408fad38f8 leon,grspw_pkt: remove incorrect comment on SMP not being tested
To clarify, SMP with GRSWP_PKT driver API has been extended to
take advantage of multi-core, is now SMP-safe, and has been tested
on GR740.
2018-08-24 15:51:39 +02:00
Daniel Hellstrom
aea3134ea9 leon,apbuart: replace termios c_cflag & CBAUD with c_{i,o}speed
ince some time RTEMS started to use the termios c_ispeed and
c_ospeed variables in the termios struct to hold the UART baudrate.
However the APBUART driver still uses the old c_cflag sometimes
causing other UART parameters to get overwritten, for example the
partiy setting no mapped to the same bits as the old CBAUD mask.

At the same time the RTEMS primitievs for setting/reading
c_{i,o}speed is now used.
2018-08-24 15:51:39 +02:00
Daniel Hellstrom
243ddb52b3 leon,greth: enable MAC filtering (promiscous mode, multicast)
It enabled promiscous mode or sets the multicast filter according
to the configuration and parameters to ioctl(SIOCSIFFLAGS),
ioctl(SIOCADDMULTI) and ioctl(SIOCDELMULTI).
On SIOCADDMULTI/SIOCDELMULTI requests the greth ioctl calls the
Ethernet helper functions ether_addmulti()/ether_delmulti() which
tells the greth driver when its required to update the MAC multicast
filtering.

The interface notifies support for multicast by setting IFF_MULTICAST.

The GRETH has two registers which contains a bit-mask of allowed MAC
addresses. The incomming MAC address is CRC:ed and the CRC is used as
an index into the bit-mask to determine to allow or drop the frame.
2018-08-24 15:51:39 +02:00
Daniel Hellstrom
2fbe2ef3ea leon, greth: 10/100 MAC enable TX BD interrupt
Missed to enable interrupt per TX descriptor. Could lead to TX buffer
starvation.

Does not affect the GBit code.
2018-08-24 15:51:39 +02:00
Daniel Hellstrom
a87964d04f sparc,smp: typo in start.S causing SMP not working 2018-08-24 15:51:38 +02:00
Daniel Cederman
59a0541c5b sparc: Restore npc when returning from the syscall_lazy_fp_switch trap
If the floating point trap occurred in a delay slot it is not certain
that npc will be equal to pc + 4.
2018-08-24 15:51:38 +02:00
Sebastian Huber
6695d02bf0 Update FreeBSD kernel timespec support
This change is based on the following FreeBSD commit:

"Make timespecadd(3) and friends public

The timespecadd(3) family of macros were imported from NetBSD back in
r35029. However, they were initially guarded by #ifdef _KERNEL. In the
meantime, we have grown at least 28 syscalls that use timespecs in some
way, leading many programs both inside and outside of the base system to
redefine those macros. It's better just to make the definitions public.

Our kernel currently defines two-argument versions of timespecadd and
timespecsub.  NetBSD, OpenBSD, and FreeDesktop.org's libbsd, however, define
three-argument versions.  Solaris also defines a three-argument version, but
only in its kernel.  This revision changes our definition to match the
common three-argument version.

Bump _FreeBSD_version due to the breaking KPI change.

Discussed with:	cem, jilles, ian, bde
Differential Revision:	https://reviews.freebsd.org/D14725"

To make the change public (outside #ifdef _KERNEL) it must be integrated
in Newlib.

Update #3472.
2018-08-23 14:39:33 +02:00
Sebastian Huber
ba0e9631a0 score: Do not inline _Thread_Dispatch_enable()
This function is slighly too complex for inlining with two if
statements.  The caller already needs a stack frame due to the potential
call to _Thread_Do_dispatch().  In _Thread_Dispatch_enable() the call to
_Thread_Do_dispatch() can be optimized to a tail call.

A text size comparision

  (text size after patch - text size before patch)
   / text size before patch

on sparc/erc32 with SMP enabled showed these results:

  Minimum -0.000697892 (fsdosfsname01.exe)
  Median -0.00745021 (psxtimes01.exe)
  Maximum -0.0233032 (spscheduler01.exe)

A text size comparision

  text size after patch - text size before patch

on sparc/erc32 with SMP enabled showed these results:

  Minimum -3312 (ada_sp09.exe)
  Median -1024 (tm15.exe)
  Maximum -592 (spglobalcon01.exe)
2018-08-23 14:38:41 +02:00
Sebastian Huber
a36aa8628f Add dummy PI_SOFT to <sys/priority.h>
Update #3472.
2018-08-23 14:38:41 +02:00
Sebastian Huber
d14f9349ea score: Fix ISR enable in _Thread_Dispatch_enable()
This bug had probably no effect since the interrupt enable is idempotent
on all CPU ports.

Close #3496.
2018-08-20 08:36:31 +02:00
Sebastian Huber
2cd3716103 bsps/arm: Fix PL111 register define re-definition
Close #3502.
2018-08-20 08:36:31 +02:00
Christian Mauderer
dcaea71741 dev/sc16is752: Add name space for field names.
The field names for the registers generated a name collision (MSR_RI on
the power pc). This patch adds a SC16IS752_ prefix for all field names.

Closes #3501.
2018-08-15 09:48:31 -05:00
Joel Sherrill
da8b12bcb7 dl06/dl06-o1.c: Remove set, not used warning 2018-08-15 09:48:28 -05:00
Joel Sherrill
adbd7e747e fsdosfssync01/init.c: Remove unused variable 2018-08-15 09:47:53 -05:00
Amaan Cheval
bc7313134f bsps/x86_64: Add APIC timer based clock driver
The APIC timer is calibrated by running the i8254 PIT for a fraction of a
second (determined by PIT_CALIBRATE_DIVIDER) and counting how many times the
APIC counter has ticked. The calibration can be run multiple times (determined
by APIC_TIMER_NUM_CALIBRATIONS) and averaged out.

Updates #2898.
2018-08-13 10:48:20 -05:00
Amaan Cheval
686932125d bsps/x86_64: Add support for RTEMS interrupts
Updates #2898.
2018-08-13 10:48:20 -05:00
Amaan Cheval
4544749e3c bsps/x86_64: Add paging support with 1GiB super pages
Updates #2898.
2018-08-13 10:48:20 -05:00
Amaan Cheval
6eccd0c7e7 bsps/x86_64: Reduce default RamSize to 1GiB
Simulators may not always be able to allocate 4GiB easily, and using an
artificially lower RAM may cause a broken heap.

Updates #2898.
2018-08-13 10:48:20 -05:00
Amaan Cheval
ab971bf5e3 bsps/x86_64: Reorganize header files and compile-options
Updates #2898.
2018-08-13 10:48:20 -05:00
Joel Sherrill
382d6537df libtests/POSIX: Fix warnings and style. 2018-08-10 08:24:29 -05:00
Joel Sherrill
b3693f5d6d bsps/sparc/include/bsp/gradcdac.h: Fix nested comment warning 2018-08-10 08:24:28 -05:00
Joel Sherrill
d071d9a17a qoriq/include/tm27.h: Fix prototype warning 2018-08-10 08:24:28 -05:00
Joel Sherrill
ebd19374c5 motorola_powerpc/include/tm27.h: Fix prototype warning 2018-08-10 08:24:28 -05:00
Joel Sherrill
3cff531fa0 bsps/powerpc/include/mpc83xx/mpc83xx.h: Fix nested comment warning 2018-08-10 08:24:28 -05:00
Joel Sherrill
5896da452c bsps/powerpc/include/bsp/tictac.h: Fix protototype warnings 2018-08-10 08:24:27 -05:00
Joel Sherrill
ae4fbf3b4f gen83xx/include/tm27.h: Fix prototype warning 2018-08-10 08:24:27 -05:00
Joel Sherrill
ec8c955d3e gen5200/include/tm27.h: Fix prototype warning 2018-08-10 08:24:27 -05:00
Joel Sherrill
7de5182999 gen5200/include/bsp/ata.h: Fix warning 2018-08-10 08:24:27 -05:00
Joel Sherrill
0fc87d4785 csb337/include/at91rm9200_dbgu.h: Fix nested comment warning 2018-08-10 08:24:26 -05:00
Sebastian Huber
b2de4260c5 score: Fix _Addresses_Subtract()
Use architecture-specific integer type for an address difference.

Update #3486.
2018-08-10 07:14:43 +02:00
Sebastian Huber
66cb142054 rtems: Parameter types in rtems_partition_create()
Use uintptr_t to specify the length of the partition buffer area instead
of uint32_t.  This is in line with rtems_region_create().  On 64-bit
targets, the length may exceed 4GiB.  Use size_t for the buffer size,
since on some targets the single object size is less than the overall
address range, e.g. m32c sizeof(uintptr_t) > sizeof(size_t).

Update #3486.
2018-08-10 07:14:43 +02:00