Commit Graph

112 Commits

Author SHA1 Message Date
Xiang Xiao 5025fbef8d Rename LIB_ to LIBC_ for all libc Kconfig
follow other libc component naming convention

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-08-05 19:45:24 +02:00
Xiang Xiao 2e54df0f35 Don't include assert.h from public header file
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-06-03 08:36:03 -07:00
Xiang Xiao 001e7c3e76 sched: Don't include nuttx/sched.h inside sched.h
But let nuttx/sched.h include sched.h instead to
avoid expose nuttx kernel API to userspace.

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-05-24 12:11:53 +09:00
Alin Jerpelea 787aca4f4e graphics: vnc: fix nxstyle errors
fix errors reported by nxstyle

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-04-03 11:56:35 -05:00
Gustavo Henrique Nihei 330eff36d7 sourcefiles: Fix relative path in file header 2021-03-09 23:18:28 +08:00
Gustavo Henrique Nihei 76acb32e29 Fix typos reported by codespell 2021-02-25 11:31:49 -08:00
Alin Jerpelea 8366a20be8 graphics: Author: Gregory Nutt: update licenses to Apache
Update files from Gregory Nutt to Apache 2.0 license.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-02-07 11:09:03 -03:00
Alin Jerpelea f177951c39 graphics: fix nxstyle errors
Fix nxstyle errors to pass CI

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-02-07 11:09:03 -03:00
Huang Qi fd78f83e02 drivers/video: Refine the update region notification mechanism
1.Expose the notification through fb_vtable_s::updatearea
2.Incorporate old nx_notify_rectangle into the new updatearea callback
3.Migrate the calle of nx_notify_rectangle to fb_vtable_s::updatearea

Change-Id: Ia3d1f73e8757b2d381586d76ec6adc16c810018d
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2020-08-10 08:08:33 +02:00
Xiang Xiao 5eae32577e build: Move INCDIROPT to common place
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-05-18 15:02:55 -06:00
Xiang Xiao d9d2fc0d0a debug: Reduce CONFIG_CPP_HAVE_VARARGS usage
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-05-05 08:27:58 -06:00
Xiang Xiao bd4fcebb95 graphics: Correct various typo error
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I2151bf7d2ce8fc5efddfa269d88c239f87eb23ba
2020-04-25 09:36:56 -06:00
Xiang Xiao 6ad91aeb05 Kconfig: change the stack size default to DEFAULT_TASK_STACKSIZE
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-04-18 07:17:38 -06:00
Gregory Nutt 97339e47f1 Check return from nxsem_wait_initialize()
Resolution of Issue 619 will require multiple steps, this part of the first step in that resolution:  Every call to nxsem_wait_uninterruptible() must handle the return value from nxsem_wait_uninterruptible properly.  This commit is only for those files under graphics/, mm/, net/, sched/, wireless/bluetooth.

Still to do:  Files under fs/, drivers/, and arch.  The last is 116 files and will take some effort.
2020-03-29 20:11:10 +01:00
Gregory Nutt 5c0e8e88b1 Revert "Makefile: move INCDIROPT to common place (#625)"
This reverts commit b9ace36fcc.

This change was added by PR 625 but has a serious logic flaw.  It removes all occurrences of INCDIROPT and replaces it with a definition in tools/Config.mk:

    else ifeq ($(WINTOOL),y)
      DEFINE = "$(TOPDIR)/tools/define.sh"
      INCDIR = "$(TOPDIR)/tools/incdir.sh" -w

This logic flaw is the Config.mk is included in all Make.defs files BEFORE WINTOOL is defined.  As a result, the definition is wrong in many places when building under Cygwin with a Windows native toolchain.
2020-03-26 08:50:29 -07:00
Xiang Xiao b9ace36fcc
Makefile: move INCDIROPT to common place (#625) 2020-03-26 08:09:59 -06:00
Xiang Xiao cde88cabcc Run codespell -w with the latest dictonary again
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-02-23 22:27:46 +01:00
Xiang Xiao bd4e8e19d3 Run codespell -w against all files
and fix the wrong correction
2020-02-22 14:45:07 -06:00
Xiang Xiao 5c80b94820 Replace #include <semaphore.h> to #include <nuttx/semaphore.h>
Since the kernel side should call nxsem_xxx instead and remove the unused inclusion
2020-02-01 08:27:30 -06:00
Xiang Xiao 0b860726db Ensure psock_socket and psock_accept initialize s_crefs to 1
This simplifies the caller usage
2020-01-31 13:45:14 -06:00
YAMAMOTO Takashi 83354983c3 Fix "with with" typos
In many cases, remove one of them.
In a few places, it looks like a typo of "width" actually.
2020-01-27 08:46:46 +01:00
YAMAMOTO Takashi 5515e09e8d Fix some "from from" in code comments 2020-01-27 08:46:46 +01:00
Xiang Xiao 346336bb9e Make the read ahead buffer unselectable
Here is the email loop talk about why it is better to remove the option:
https://groups.google.com/forum/#!topic/nuttx/AaNkS7oU6R0

Change-Id: Ib66c037752149ad4b2787ef447f966c77aa12aad
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-01-11 08:24:49 -06:00
Xiang Xiao 6a3c2aded6 Fix wait loop and void cast (#24)
* Simplify EINTR/ECANCEL error handling

1. Add semaphore uninterruptible wait function
2 .Replace semaphore wait loop with a single uninterruptible wait
3. Replace all sem_xxx to nxsem_xxx

* Unify the void cast usage

1. Remove void cast for function because many place ignore the returned value witout cast
2. Replace void cast for variable with UNUSED macro
2020-01-02 10:54:43 -06:00
Nathan Hartman 366053e464 Fix typos, 1 in a #define, others in comments. This changes one definition: _MQ_TIMEDRECIEVE is changed to _MQ_TIMEDRECEIVE. It appears this symbol is not used anywhere. 2019-09-11 08:56:56 -06:00
Nathan Hartman 91ef2ec394 Fix a few minor typos 2019-09-08 15:59:14 -06:00
Gregory Nutt 8130038fb0 configs/same70-xplained/twm4nx/defconfig: Switch to 8BPP. That is the negotiated size requested by the VNC client anyway. graphics/vnc/server/vnc_color.c: Fix an error in color conversion. 2019-05-03 17:08:05 -06:00
Gregory Nutt 03f345b38c configs/same70-xplained/twm4nx/defconfig: Increase packet MTU to 1500. 2019-05-03 10:45:38 -06:00
Gregory Nutt cbb09c55ec graphics/nxbe and nxmu: This bring the software cursor to code complete. Still untested. Some flicker is expected. It has not been determined if that level of flicker is acceptable or not. 2019-04-09 15:09:10 -06:00
Gregory Nutt 2c2729521b Abandon attempt to get common data structures for NX and the raw framebuffer cursor interface. This backs out several changes. 2019-04-07 18:00:40 -06:00
Gregory Nutt 04b723e447 Squashed commit of the following:
include/nuttx/nx/nxcursor.h:  Add a header file descrbing the implementation of an NX cursor interface.  There is no implementation in place yet.

    include/nuttx/video/cursor.h:  Separate out cursor definitions from fb.h.  Other graphic interfaces other than a framebuffer may support a cursor, possible a software cursor.
2019-04-06 12:18:05 -06:00
Gregory Nutt 92554257b9 Squashed commit of the following:
graphics/nxbe/nxbe_bitmap.c:  Fix another coordinate system problem.

    graphics/:  Review use of device coordinate system with window frambebuffer and make fixes accordingly.

    graphics/nxbe/nxbe_fill.c:  Fix a coordinate system bug.  Was trying to update the window fraembuffer using the device coordinate system.  Need to use the relative coordinate system.

    graphics/:  Use DEBUGASSERT instead of return an error since the is no user to handle the errors within the NX server.  Use CONFIG_DEBUG_GRAPHICS instead of CONFIG_DEBUG_FEATURES in most cases.

    graphics/:  Nothing under graphics/ should set the errno.
2019-03-17 11:34:45 -06:00
Gregory Nutt 9546481054 Fix some typographical errors. 2018-09-14 06:55:45 -06:00
Alan Carvalho de Assis 283b73edc5 Fix lots of typos in C comments and Kconfig help text 2018-07-08 18:24:45 -06:00
Gregory Nutt 668df010ec Committed defconfigs for working configurations should never have CONFIG_EXPERIMENTAL set because the opens the doors for untested and incomplete configurations. Conversely, if there are released configurations that use features with dependencies on CONFIG_EXPERIMENTAL, then those configurations are in use and those dependencies should be removed:
graphics/vnc/server/Kconfig:  Remove a dependency on CONFIG_EXPERIMENTAL
net/tcp/Kconfig:  Remove a dependency on CONFIG_EXPERIMENTAL
wireless/bluetooth/Kconfig:  Remove a dependency on CONFIG_EXPERIMENTAL

configs/lc823450-xgevk/audio/defconfig:  Remove CONFIG_EXPERIMENTAL=y
configs/lc823450-xgevk/bt/defconfig:  Remove CONFIG_EXPERIMENTAL=y
configs/lc823450-xgevk/ipl2/defconfig:  Remove CONFIG_EXPERIMENTAL=y
configs/lc823450-xgevk/nsh/defconfig:  Remove CONFIG_EXPERIMENTAL=y
configs/lc823450-xgevk/rndis/defconfig:  Remove CONFIG_EXPERIMENTAL=y
configs/lc823450-xgevk/usb/defconfig:  Remove CONFIG_EXPERIMENTAL=y
configs/lpcxpresso-lpc54628/netnsh/defconfig:  Remove CONFIG_EXPERIMENTAL=y
configs/moxa/nsh/defconfig:  Remove CONFIG_EXPERIMENTAL=y
configs/olimex-stm32-p407/module/defconfig:  Remove CONFIG_EXPERIMENTAL=y
configs/photon/wlan/defconfig:  Remove CONFIG_EXPERIMENTAL=y
configs/sabre-6quad/smp/defconfig:  Remove CONFIG_EXPERIMENTAL=y
configs/sam4cmp-db/nsh/defconfig:  Remove CONFIG_EXPERIMENTAL=y
configs/sama5d4-ek/elf/defconfig:  Remove CONFIG_EXPERIMENTAL=y
configs/sama5d4-ek/knsh/defconfig:  Remove CONFIG_EXPERIMENTAL=y
configs/samv71-xult/module/defconfig:  Remove CONFIG_EXPERIMENTAL=y
configs/samv71-xult/vnc/defconfig:  Remove CONFIG_EXPERIMENTAL=y
configs/samv71-xult/vnxwm/defconfig:  Remove CONFIG_EXPERIMENTAL=y
configs/sim/bluetooth/defconfig:  Remove CONFIG_EXPERIMENTAL=y
configs/sim/pf_ieee802154/defconfig:  Remove CONFIG_EXPERIMENTAL=y
configs/sim/pktradio/defconfig:  Remove CONFIG_EXPERIMENTAL=y
configs/sim/sixlowpan/defconfig:  Remove CONFIG_EXPERIMENTAL=y
configs/sim/traveler/defconfig:  Remove CONFIG_EXPERIMENTAL=y
configs/sim/userfs/defconfig:  Remove CONFIG_EXPERIMENTAL=y
configs/stm32f4discovery/hciuart/defconfig:  Remove CONFIG_EXPERIMENTAL=y
configs/stm32f4discovery/pseudoterm/defconfig:  Remove CONFIG_EXPERIMENTAL=y
configs/teensy-3.x/usbnsh/defconfig:  Remove CONFIG_EXPERIMENTAL=y
2018-06-17 10:30:01 -06:00
Gregory Nutt b54ffe858a Standardization of some function headers. 2018-03-13 09:52:27 -06:00
Gregory Nutt 12474d2c38 Eliminate new warnings due to unused local variables noted in build testing. 2018-02-01 10:25:48 -06:00
Gregory Nutt 7cf88d7dbd Make sure that labeling is used consistently in all function headers. 2018-02-01 10:00:02 -06:00
Gregory Nutt 770a83bc7d graphics/vnc: Correct a typo introduced in last large set of changes 2018-01-31 11:31:12 -06:00
Gregory Nutt 30f2927101 binfmt/, drivers/, graphics/: Fix several inappropriate accesses to get_errno() that were missed in previous changes (some going back to nuttx-.23). 2018-01-30 17:23:10 -06:00
Gregory Nutt 5b385f4d4d kthread_create(): Rename kernel_thread() to kthread_create() for better naming consistency with task_create() and kthread_delete(). 2017-10-16 11:38:00 -06:00
Gregory Nutt 700f1a8e8c Eliminate some warnings found in build testing. 2017-10-08 16:27:17 -06:00
Gregory Nutt 10e7105900 graphics/vnc/server: Fix an error in the VNC server introduced with recent big set of changes. 2017-10-07 08:30:50 -06:00
Gregory Nutt 9568600ab1 Squashed commit of the following:
This commit backs out most of commit b4747286b1.  That change was added because sem_wait() would sometimes cause cancellation points inappropriated.  But with these recent changes, nxsem_wait() is used instead and it is not a cancellation point.

    In the OS, all calls to sem_wait() changed to nxsem_wait().  nxsem_wait() does not return errors via errno so each place where nxsem_wait() is now called must not examine the errno variable.

    In all OS functions (not libraries), change sem_wait() to nxsem_wait().  This will prevent the OS from creating bogus cancellation points and from modifying the per-task errno variable.

    sched/semaphore:  Add the function nxsem_wait().  This is a new internal OS interface.  It is functionally equivalent to sem_wait() except that (1) it is not a cancellation point, and (2) it does not set the per-thread errno value on return.
2017-10-04 15:22:27 -06:00
Gregory Nutt 42a0796615 Squashed commit of the following:
sched/semaphore:  Add nxsem_post() which is identical to sem_post() except that it never modifies the errno variable.  Changed all references to sem_post in the OS to nxsem_post().

    sched/semaphore:  Add nxsem_destroy() which is identical to sem_destroy() except that it never modifies the errno variable.  Changed all references to sem_destroy() in the OS to nxsem_destroy().

    libc/semaphore and sched/semaphore:  Add nxsem_getprotocol() and nxsem_setprotocola which are identical to sem_getprotocol() and set_setprotocol() except that they never modifies the errno variable.  Changed all references to sem_setprotocol in the OS to nxsem_setprotocol().  sem_getprotocol() was not used in the OS
2017-10-03 15:35:24 -06:00
Gregory Nutt 83cdb0c552 Squashed commit of the following:
libc/semaphore:  Add nxsem_getvalue() which is identical to sem_getvalue() except that it never modifies the errno variable.  Changed all references to sem_getvalue in the OS to nxsem_getvalue().

    sched/semaphore:  Rename all internal private functions from sem_xyz to nxsem_xyz.  The sem_ prefix is (will be) reserved only for the application semaphore interfaces.

    libc/semaphore:  Add nxsem_init() which is identical to sem_init() except that it never modifies the errno variable.  Changed all references to sem_init in the OS to nxsem_init().

    sched/semaphore:  Rename sem_tickwait() to nxsem_tickwait() so that it is clear this is an internal OS function.

    sched/semaphoate:  Rename sem_reset() to nxsem_reset() so that it is clear this is an internal OS function.
2017-10-03 12:52:31 -06:00
Gregory Nutt 2c2aa94b7d Squashed commit of the following:
net/: psock_recvfrom() is an internal interface and should not set the errno nor should it be a cancellation point.

    net/: psock_accept() is not a cancellation point.

    net/: psock_getsockopt() and psock_socket*9 are an internal interfaces and should not set the errno.

    net/: psock_getsockopt() is an internal interface and should not set the errno.

    net/: psock_listen() is an internal interface and should not set the errno.

    net/: psock_connect(( is an internal interface and should not set the errno nor should it be a cancellation point.

    net/: psock_bind() is an internal interface and should not set the errno.

    net/: psock_accept() is an internal interface and should not set the errno.
2017-09-30 08:18:08 -06:00
Gregory Nutt 44736b721c net/sockets: psock_send() is an internal OS interface an should not set the errno variable. 2017-09-29 17:48:15 -06:00
Gregory Nutt 0de294a586 Fix lots of occurrences of 'the the', 'the there', 'the these', 'the then', 'the they. 2017-05-11 13:35:56 -06:00
Gregory Nutt d5207efb5a Be consistent... Use Name: consistent in function headers vs Function: 2017-04-21 16:33:14 -06:00