Commit Graph

5571 Commits

Author SHA1 Message Date
zhangyuan21
aa9f15d635 arch_alarm: change tick to g_current_tick
When the system starts up, the hw count may not start counting from 0,
which can cause the processing time of the first oneshot handler to be
too long. Therefore, the current tick value should be set based on the
hw count during initialization.

Signed-off-by: zhangyuan21 <zhangyuan21@xiaomi.com>
2023-09-06 17:28:26 +08:00
likun17
7d7345a620 sensor/bmp180.c:provides work in character device mode and UORB communication mode.
Use the macro CONFIG_SENSORS_BMP180_UORB to enable the uorb feature.

Signed-off-by: likun17 <likun17@xiaomi.com>
2023-09-06 08:02:52 +02:00
Jukka Laitinen
7ec3cad5af drivers/timers/pcf85263.c: Fix compilation
Add the missing semicolons

Signed-off-by: Jukka Laitinen <jukkax@ssrc.tii.ae>
2023-09-06 12:20:57 +08:00
zhangyuan21
0efd4d0e12 usbdev: Split usbdev descriptor information
The class device only handles descriptor information specific to the class,
and shared descriptor information is passed through parameters and
handled by the composite driver.

Signed-off-by: zhangyuan21 <zhangyuan21@xiaomi.com>
2023-09-06 02:29:32 +08:00
likun17
b5bccbb70e sensor:bmi160.c:Fix the missing items caused by resolving merge conflicts after bmi160 cherry-pick submission. This cherry-pick missing CI check did not detect it.
Signed-off-by: likun17 <likun17@xiaomi.com>
2023-09-06 02:24:35 +08:00
Xiang Xiao
a9efeeeebc drivers/clk: Change CLK_SET_RATE_NO_REPARENT to CLK_MUX_SET_RATE_NO_REPARENT
since only mux clk use this flag

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-09-05 18:05:50 +03:00
Tiago Medicci Serrano
9357d70c25 audio/cs4344: Set master clock when resetting the device
Whevenever the bit rate is going to be set, it's necessary to first
set the master clock if the underlying device supports it. If it
fails, just return the error code.
2023-09-05 13:33:05 +08:00
Tiago Medicci Serrano
d9169b84e4 audio/cs4344: Set the default sample rate to the lowest possible
According to the struct `mclk_rate_s`, set the default sample rate
to its lowest valid value. This prevents the underlying driver from
setting unsupported values.
2023-09-05 13:33:05 +08:00
likun17
ad643fe7a3 sensor/bmi160.c:provides work in character device mode and UORB communication mode.
Create bmi160_base.h, bmi160_base.c bmi160_uorb.c files, the bmi160_base file stores
public function interfaces, and the bmi160_uorb file stores functions related to the
uorb framework. Switch the character interface and UORB interface through the
macro CONFIG_SENSORS_BMI160_UORB.

Signed-off-by: likun17 <likun17@xiaomi.com>
2023-09-04 08:17:44 +02:00
likun17
bc066af50a sensor/bmi160.c:provides work in character device mode and UORB communication mode.
create a new bmi160.h file.

Signed-off-by: likun17 <likun17@xiaomi.com>
2023-09-04 08:17:44 +02:00
TimJTi
3b4ea52a79 Remove spinlock, change to i2c_readwrite where appropriate , and consolidate i2c read and write calls. 2023-09-02 16:26:10 +03:00
zhangyuan21
06d9356d12 usbdev: Use BOARD_USBDEV_SERIALSTR config directly
A usbdev has only one serial string, so use a unique macro to control it.

For boards that enable board serial string using COMPOSITE_BOARD_SERIALSTR,
PL2303_BOARD_SERIALSTR, CDCACM_BOARD_SERIALSTR, USBADB_BOARD_SERIALSTR,
USBMSC_BOARD_SERIALSTR, and RNDIS_BOARD_SERIALSTR, they need to be replaced
with BOARD_USBDEV_SERIALSTR.

Signed-off-by: zhangyuan21 <zhangyuan21@xiaomi.com>
2023-09-01 19:29:12 +08:00
zhanghongyu
b30a389459 usrsock_server: fix coverity for recvfrom handle
req->usockid may not be in a valid range when ret less than zero and not -EAGAIN.

Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2023-09-01 12:30:54 +03:00
chao an
664927c86e mm/alloc: remove all unnecessary cast for alloc
Fix the minor style issue and remove unnecessary cast

Signed-off-by: chao an <anchao@xiaomi.com>
2023-08-30 14:34:20 +08:00
Eero Nurkkala
db13d5e24c drivers/mmcsd: fix regression causing emmcsd not working
Commit 50a8ec6 broke many mmc devices.  Only if the flag
priv->caps & SDIO_CAPS_4BIT_ONLY was set, it migth work.
Without the flag, the mmc clock is never set (mmcsd_widebus()
call is terminated early stopping the clock).  This flag
is probably not very generic because most mmc hw support
1, 4 and 8 bit modes.

JEDEC specifies a bus width selection procedure, but it's
not implemented in this mmcsd_sdio.c driver.  Thus, it's
not known whether the hw supports 1, 4 anf 8 bit modes or
a combination of them.

However, with priv->caps & SDIO_CAPS_4BIT_ONLY the driver
suddenly assigns priv->buswidth = MMCSD_SCR_BUSWIDTH_4BIT
making it the only way to have the driver working.

Fix this by relaxing the above mentioned restrictions.

Signed-off-by: Eero Nurkkala <eero.nurkkala@offcode.fi>
2023-08-30 14:33:32 +08:00
dongjiuzhu1
c983aee38a driver/serial: fix race condition about calling rxflowcontrol in mutli thread
Signed-off-by: dongjiuzhu1 <dongjiuzhu1@xiaomi.com>
2023-08-30 14:33:00 +08:00
dongjiuzhu1
ec4f6ecce2 driver/serial: fix error echo about VT100 escape sequence
Signed-off-by: dongjiuzhu1 <dongjiuzhu1@xiaomi.com>
2023-08-30 14:26:11 +08:00
Michal Lenc
f9d4a47889 pcf8575: fix compilation warnings
Just few compile warning fixes in case CONFIG_IOEXPANDER_MULTIPIN is
selected.

Signed-off-by: Michal Lenc <michallenc@seznam.cz>
2023-08-29 20:34:12 +08:00
Michal Lenc
b005f844f5 ioexpander: add support for ISO1I813T expander
This commit adds basic support for electrically isolated 8 bit expander.
The expander communicates with the MCU via SPI interface. Both single
and multiple pin read are supported.

Signed-off-by: Michal Lenc <michallenc@seznam.cz>
2023-08-29 17:35:59 +08:00
chao an
b60f01a55b inode/i_private: remove all unnecessary cast for i_private
Signed-off-by: chao an <anchao@xiaomi.com>
2023-08-29 08:58:07 +02:00
SPRESENSE
f556cb106a drivers/video: Fix an issue isx019 may freeze
isx019 driver freezes by I2C access in the interrupt context.
This I2C access is intended to stop data output from FPGA.
Delete this I2C access for the following reasons.
- Data output from FPGA does not affect power consumption
- There are no problems in capture restart without data output stop
  since restart is done by image data block first.
2023-08-29 13:37:01 +08:00
Michal Lenc
fa63ef69c9 ioexpander: add support for ISO1H812G expander
This commit adds support for galvanic isolated ISO1H812G SPI expander.
Both single pin and multiple pin writes are supported.

Signed-off-by: Michal Lenc <michallenc@seznam.cz>
2023-08-29 10:31:40 +08:00
chao an
7aa45305b7 fs/inode: remove all unnecessary check for filep/inode
Since VFS layer already contains sanity checks, so remove unnecessary lower half checks

Signed-off-by: chao an <anchao@xiaomi.com>
2023-08-29 09:47:11 +08:00
dulibo1
127bd81674 regulator:check id conflict when register
Signed-off-by: dulibo1 <dulibo1@xiaomi.com>
2023-08-29 02:59:59 +08:00
Alan Carvalho de Assis
7f62e315c6 bh1750fvi: Fix compilation error
Error: sensors/bh1750fvi.c:73:16: error: unused function 'bh1750fvi_open' [-Werror,-Wunused-function]
static int     bh1750fvi_open(FAR struct file *filep);
               ^
Error: sensors/bh1750fvi.c:74:16: error: unused function 'bh1750fvi_close' [-Werror,-Wunused-function]
static int     bh1750fvi_close(FAR struct file *filep);
2023-08-28 21:03:19 +03:00
yinshengkai
02d0762c6e driver/note: fix trace dump: dump failed
Exceeding the length limit may cause an error when using sched_note_printf

Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-08-29 00:09:10 +08:00
raiden00pl
8665acaffa lsm9ds1.c: fix printf warnings 2023-08-27 10:05:05 +08:00
raiden00pl
7109fd6121 sensors/Kconfig: fix wrong depends on SN_XXX 2023-08-26 20:00:12 +08:00
SPRESENSE
f7400a857d drivers/audio/cxd56: Move cxd56 sources into arch/cxd56xx
CXD56 audio functions are inside of the CXD56.
So implementation of it should be under arch directory.
2023-08-26 01:20:32 +08:00
ligd
b743d62703 syslog: remove unsed check
To simplify the code

Signed-off-by: ligd <liguiding1@xiaomi.com>
2023-08-25 17:31:31 +08:00
Jiuzhu Dong
904ca21a00 syslog & ramlog: add BOARDIOC_RESET_CAUSE for syslog & ramlog
cold boot should clear syslog & ramlog buffer

Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
Signed-off-by: ligd <liguiding1@xiaomi.com>
2023-08-25 17:31:31 +08:00
chengkai
d867c46bbc serial/uart/h5: add bt h5 uart serial driver
Signed-off-by: chengkai <chengkai@xiaomi.com>
2023-08-25 17:17:37 +08:00
Michal Lenc
00128ff2fe pwm: fix incorrect documentation for PWMIOC_SETCHARACTERISTICS IOCTL
Documentation for PWMIOC_SETCHARACTERISTICS ioctl command mentioned
that this command will neither start nor stop the pulsed output. This
however is incorrect as PWMIOC_SETCHARACTERISTICS command leads to
pwm_start() function which starts the pulsed output.

While this might not be the correct behaviour (I would probably welcome
the option to set PWM characteristics without starting the pulsed output)
it is the way the PWM driver is coded for many architectures. Future
enhancement might be to add function pwm_setchar() for example to just
set characteristics without starting the PWM output.

Signed-off-by: Michal Lenc <michallenc@seznam.cz>
2023-08-24 01:37:40 +08:00
raiden00pl
a72b8e2fd4 cmake: drivers/segger support 2023-08-22 23:37:08 +08:00
guohao15
d4cebd5d77 mtd:add dhara compatiblity layer
to support dhara ftl for fatfs

Signed-off-by: guohao15 <guohao15@xiaomi.com>
2023-08-22 23:16:14 +08:00
xiajizhong
1c860f38e7 cordic API add scale parameter
Signed-off-by: xiajizhong <xiajizhong@xiaomi.com>
2023-08-22 12:51:36 +02:00
Zhe Weng
5597b8a9e2 drivers/virtio-net: Add support to offload small IOBs
TCP receive tested with different IOB_BUFSIZE:
|             | 256B vs 1534B | 512B vs 1534B | 768B vs 1534B |
| :---------: | :-----------: | :-----------: | :-----------: |
|     Non-SMP |     ~85%      |     ~93%      |     ~96%      |
|  armv8a-SMP |     ~66%      |     ~84%      |     ~92%      |
| rv32/64-SMP |     ~52%      |     ~72%      |     ~83%      |

It seems we still get performance penalty on smaller IOBs, and may be
affected more under SMP mode. It may be caused by critical sections in
IOB operations.

Signed-off-by: Zhe Weng <wengzhe@xiaomi.com>
2023-08-22 16:34:21 +09:00
Zhe Weng
318d136320 netdev/upper: Add netpkt_to_iov() interface
Some driver like virtio-net can offload fragmented IOBs, so an interface
to support this feature is needed.

Signed-off-by: Zhe Weng <wengzhe@xiaomi.com>
2023-08-22 16:34:21 +09:00
Zhe Weng
d44e19d115 mm/iob: Add support for increasing length in iob_update_pktlen
Signed-off-by: Zhe Weng <wengzhe@xiaomi.com>
2023-08-22 16:34:21 +09:00
Zhe Weng
2fa68fbddd drivers/virtio-net: Support different LL_GUARDSIZE
Previously, the CONFIG_NET_LL_GUARDSIZE is fixed to 32 (64-Bit) or
28 (32-Bit), it's a little bit tricky.
Now add support to any value greater than minimal size.

Signed-off-by: Zhe Weng <wengzhe@xiaomi.com>
2023-08-22 16:34:21 +09:00
zhangyuan21
9bccd94fee rndis: Fixing erroneous macros
Signed-off-by: zhangyuan21 <zhangyuan21@xiaomi.com>
2023-08-22 01:31:19 +08:00
dongjiuzhu1
38c001a914 drivers/pipes: fix busyloop issue when circbuf is full
pipecommon_poll always reutrn POLLOUT when the circbuf is full.

Signed-off-by: dongjiuzhu1 <dongjiuzhu1@xiaomi.com>
2023-08-22 01:30:17 +08:00
Xiang Xiao
90f8315432 arch: Remove up_netinitialize
since this api change to xxx_netinitialize

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-08-20 14:33:17 +03:00
Petro Karashchenko
075738cf14 net/ip: print ip addresses using ip4_addrN macro
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-08-19 13:28:21 -03:00
yinshengkai
8fa4f2d61d add the startup process tracepoint
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-08-19 21:50:08 +08:00
yinshengkai
1e164b7f75 note: add noteram crash dump
Dump all content when a crash occurs

Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-08-19 21:48:56 +08:00
guohao15
2740f377eb ftl: fix ftl_flush will read/erase beyond the end of the partition
Signed-off-by: guohao15 <guohao15@xiaomi.com>
2023-08-19 21:47:14 +08:00
rongyichang
917634446e drivers/lcd : add ioctl passthrough for LCD driver
Some LCD vendors support unit test commands, we should passthrough the ioctl
commands to drivers.

Signed-off-by: rongyichang <rongyichang@xiaomi.com>
2023-08-19 01:50:41 +08:00
dongjiuzhu1
29ddfd44a0 driver/note: dump irq handler address to trace
Signed-off-by: dongjiuzhu1 <dongjiuzhu1@xiaomi.com>
2023-08-19 01:42:17 +08:00
ligd
45c04e9125 syslog_rpmsg: update check method when do flush()
Signed-off-by: ligd <liguiding1@xiaomi.com>
2023-08-19 01:35:19 +08:00
zhanghongyu
7b11162b24 rpmsgdev: add tun device ioctl support
In a multi-core heterogeneous architecture, tun device nodes of protocol
stack core can be accessed by other cores through ioctl

Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2023-08-19 01:33:17 +08:00
simbit18
70ab01a20b Fix Kconfig style
Replace help => ---help---
Remove spaces from Kconfig
Add comments
2023-08-18 16:36:04 +03:00
xucheng5
417207678e driver/capture : add capture debug, fixed compile warning
Signed-off-by: xucheng5 <xucheng5@xiaomi.com>
2023-08-18 09:21:46 +02:00
Takayoshi Koizumi
d5407b16f8 driver/audio/cxd56: Fix code style
Fix the code pointed out.
2023-08-18 08:53:04 +02:00
SPRESENSE
035a00e286 driver/audio/cxd56: Support 24bit, 192kHz and 4ch max
Support CXD56 audio input for 192kHz sampleing rate,
24bit and 4channels.
2023-08-18 08:53:04 +02:00
xuwenjie
4af8927829 drivers/pty: Support get and set local mode of pty
Signed-off-by: xuwenjie <xuwenjie1@xiaomi.com>
2023-08-18 14:30:22 +08:00
Jiuzhu Dong
fa10cf7cdf driver/sensor: update nbuffer to upper state
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2023-08-18 12:20:50 +08:00
p-zhangliming1
4b2ae15069 nuttx/mtd: Add new functions part_isbad and part_markbad in mtd partition.
Signed-off-by: p-zhangliming1 <p-zhangliming1@xiaomi.com>
2023-08-16 23:56:18 +03:00
zhangyuan21
1e7678c58a usbdev: clear configid after class disconnect
In class disconnect, resetconfig will be performed based on
configid, so configid should be cleared after disconnect.

Signed-off-by: zhangyuan21 <zhangyuan21@xiaomi.com>
2023-08-17 01:11:53 +08:00
xuxin19
f2f0d7fbad cmake:fix drivers build block during cmake reforming
Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
2023-08-16 22:38:52 +08:00
wangyingdong
8f6f601ec1 net/local:Add peek support for pipe and MSG_PEEK support for local socket
fifo peek example:
struct pipe_peek_s peek_buf;
peek_buf.len = len;
peek_buf.data = buf;
ret = file_ioctl(filep, PIPEIOC_PEEK,(unsigned long)((uintptr_t)&peek_buf));

Signed-off-by: wangyingdong <wangyingdong@xiaomi.com>
2023-08-15 23:58:45 +08:00
liuhongchao
f9dbeaef86 drivers/input:fix circbuf leak
Signed-off-by: liuhongchao <liuhongchao@xiaomi.com>
2023-08-14 20:40:11 +08:00
yinshengkai
b106f032cb drivers/note: add maximum channel number check
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-08-14 13:41:00 +08:00
dulibo1
3591de08c6 fix g_goldfish_gauge_ops init C89 compatible and align style
Signed-off-by: dulibo1 <dulibo1@xiaomi.com>
2023-08-14 13:40:38 +08:00
jianglianfang
5accd7c146 drivers/video: add Goldfish-FB driver
the register definition is described here:
https://android.googlesource.com/platform/external/qemu/+/master/docs/GOLDFISH-VIRTUAL-HARDWARE.TXT

Goldfish-FB driver is to communicate with Goldfish-FB in QEMU, and push the framebuffer data to the emulator for display on the screen.
test: CONFIG_GOLDFISH_FB =1, and run demo=>lvgldemo widgets

Signed-off-by: jianglianfang <jianglianfang@xiaomi.com>
2023-08-13 11:51:30 -03:00
rongyichang
72587c6e79 drivers/virtio: add virtio input driver
Signed-off-by: liuhongchao <liuhongchao@xiaomi.com>
2023-08-13 11:47:39 -03:00
hujun5
c712a00620 drivers/input: rm sched_[un]lock
We use enter_critical_section to protect the read and write of priv structures,
sched_lock is mainly used to prevent active context switching caused by nxsem_post.
We do not actively switch contexts when reading and writing priv structures,
so sched_lock can be removed.

Signed-off-by: hujun5 <hujun5@xiaomi.com>
2023-08-12 23:32:38 +08:00
wangming9
c928acc9ff perf: The new configuration supports hardware performance counting
Adding the CONFIG_ARCH_PERF_EVENTS configuration to enable
hardware performance counting,solve the problem that some platform
hardware counting support is not perfect, you can choose to use
software interface.

This is configured using CONFIG_ARCH_PERF_EVENTS, so weak_functions
are removed to prevent confusion

To use hardware performance counting, must:
1. Configure CONFIG_ARCH_PERF_EVENTS, default selection
2. Call up_perf_init for initialization

Signed-off-by: wangming9 <wangming9@xiaomi.com>
2023-08-12 02:20:44 +08:00
huxiandong
cd5ee3fb07 spi/slave: use POLLPRI to notify TX_COMPLETE.
Signed-off-by: huxiandong <huxiandong@xiaomi.com>
2023-08-12 02:02:50 +08:00
chao an
65c30f9dbd drivers/misc/rpmsgblk: fix build break if CONFIG_DISABLE_PSEUDOFS_OPERATIONS
In function ‘rpmsgblk_unlink_handler’:
misc/rpmsgblk_server.c:340:36: error: ‘const struct block_operations’ has no member named ‘unlink’
  340 |   msg->header.result = server->bops->unlink(server->blknode);
      |

Signed-off-by: chao an <anchao@xiaomi.com>
2023-08-11 21:20:40 +08:00
shipei
3cabf7ced8 audio:add virtio snd driver
playback test:
nxplayer
device /dev/audio/pcm0p
playraw /data/test.wav 2 16 44100
stop

record test:
nxrecorder
device /dev/audio/pcm0c
recordraw /data/rec.pcm 2 16 16000
stop

Signed-off-by: shipei <shipei@xiaomi.com>
2023-08-11 20:40:40 +08:00
yangshuyong
e0dc140d1c added mutex lock before lookup reset controller by name
Signed-off-by: yangshuyong <yangshuyong@xiaomi.com>
2023-08-11 20:39:16 +08:00
yangshuyong
9c4e608529 Fixed the reset format error
Signed-off-by: yangshuyong <yangshuyong@xiaomi.com>
2023-08-11 20:39:16 +08:00
yangshuyong
6f6977d002 support nuttx reset driver model
Signed-off-by: yangshuyong <yangshuyong@xiaomi.com>
2023-08-11 20:39:16 +08:00
xiajizhong
b84fbe87ee math acceleration api support FFT
Signed-off-by: xiajizhong <xiajizhong@xiaomi.com>
2023-08-11 20:38:00 +08:00
xiajizhong
f922f4cc61 expand cordic_register to math_register
Signed-off-by: xiajizhong <xiajizhong@xiaomi.com>
2023-08-11 20:38:00 +08:00
liuhongchao
69b655f4b2 drivers/input:support mouse driver
Implement mouse driver lower upper

Signed-off-by: liuhongchao <liuhongchao@xiaomi.com>
2023-08-11 20:37:11 +08:00
Peter Bee
78b993c4e8 drivers/virtio: add virtio gpu driver
This patch provides basic framebuffer display support for virtio.
Multiple displays are supported.

Signed-off-by: Peter Bee <bijunda1@xiaomi.com>
2023-08-11 20:20:11 +08:00
yinshengkai
bc181f3f9c drivers/rtt: add rtt syslog channel configuration
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-08-11 18:13:52 +08:00
dulibo1
3f9a76e131 battery:add goldfish battery driver
support the goldfish emulator battery driver

Signed-off-by: dulibo1 <dulibo1@xiaomi.com>
2023-08-11 15:30:35 +08:00
zhanghongyu
dd080773cc usrsock_server: coverity fix for access invalid index
req->usockid maybe < 0 or > CONFIG_NET_USRSOCK_RPMSG_SERVER_NSOCKS,
if so , priv->pfds[req->usockid] will access invalid memory.

Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2023-08-11 15:29:59 +08:00
zhanghongyu
0ead147841 rpmsgdev: support single read/write mode device
The default mode for Rpmsgdev is to read/write data as long as possible for
caller, this mode does not apply to tun devices, tun devices can read and
write only one complete ip packet at a time.

Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2023-08-11 15:29:32 +08:00
zhanghu5
305c213d15 filter out control character in pty echo
Signed-off-by: zhanghu5 <zhanghu5@xiaomi.com>
2023-08-11 13:58:54 +08:00
yinshengkai
67cb1d1650 note: simplify noteram logic
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-08-11 13:27:17 +08:00
yinshengkai
e69dd5f705 noteram: remove task_context
syscall cannot be called in syscall, if this happens, it should be fixed (interruption is similar)

Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-08-11 13:27:17 +08:00
yinshengkai
4aa13542d1 note: remove the name field of task_context
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-08-11 13:27:17 +08:00
yinshengkai
4cb2d7dc25 note: directly returns the taskname pointer
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-08-11 13:27:17 +08:00
yinshengkai
84799d15ac note: remove NOTERAM_GETTASKNAME
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-08-11 13:27:17 +08:00
yinshengkai
39001e3705 drivers/noteram: move trace_dump to noteram
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-08-11 13:27:17 +08:00
sunkun3
7ba9236c54 usbdev/composite: winusb devices are not automatically recognized by windows
Description bMS_VendorCode is incorrectly configured. Change it to
USB_REQ_GETMSFTOSDESCRIPTOR(0xee), which is the same as the request
processing logic for GET_MS_DESCRIPTOR in the code

Signed-off-by: sunkun3 <sunkun3@xiaomi.com>
2023-08-11 13:19:13 +08:00
sunkun3
052d46c690 usbdev: a memory leak occurred when the usb uninitialize process was executed
In usbclass_unbind, DEV_FREEEP is called first, and later
usbclass_freereq does not free memory due to ep NULL

Signed-off-by: sunkun3 <sunkun3@xiaomi.com>
2023-08-11 13:19:13 +08:00
liuhongchao
7dde402982 drivers/input:Fix setting the number of keyboard driver buffers fails
Buffer nums is not multiplied by the structure size

Signed-off-by: liuhongchao <liuhongchao@xiaomi.com>
2023-08-11 13:17:54 +08:00
zhanghu5
a69b6846e6 fix byte_block_count error in byte mode
Signed-off-by: zhanghu5 <zhanghu5@xiaomi.com>
2023-08-11 13:15:57 +08:00
dulibo1
af60bf8213 regulator:optimize the lock to support call the interface in idle task by pm
support call api in idle task

Signed-off-by: dulibo1 <dulibo1@xiaomi.com>
2023-08-10 23:17:51 +08:00
dulibo1
1456919e58 regulator:support lp mode and auto pm register
1.add new intf regulator_set_mode to manual set rehulator lower power mode;
2.when add auto lp desc,the regulator lp mode is controlled by  pm framework;

Signed-off-by: dulibo1 <dulibo1@xiaomi.com>
2023-08-10 23:17:51 +08:00
dulibo1
935359fa3f regulator: support link to supply
when add supply desc,the regulator is linked to the parent regulator
1.if enable the regualtor, the parent regulator is enabled
2.if disable all child regulator, the parent regualtor is disabled

Signed-off-by: dulibo1 <dulibo1@xiaomi.com>
2023-08-10 23:17:51 +08:00
dulibo1
67aa12e762 regulator:support always on
when add always on desc,the regulator is always enabled

Signed-off-by: dulibo1 <dulibo1@xiaomi.com>
2023-08-10 23:17:51 +08:00
zhanghu5
5890fde1ed drivers/input: Implement the debounce in button_upper.c
use delay configurable watchdog to implement debounce

Signed-off-by: zhanghu5 <zhanghu5@xiaomi.com>
2023-08-10 23:14:26 +08:00
yintao
26f996b927 nuttx/input: fix uinput_rpmsg_device_destroy crash
Signed-off-by: yintao <yintao@xiaomi.com>
2023-08-10 23:13:40 +08:00
wangbowen6
9aa57b6c53 virtio: add virtio framework in NuttX
1. virtio devics/drivers match and probe/remote mechanism;
2. virtio mmio transport layer based on OpenAmp (Compatible with both
   virtio mmio version 1 and 2);
3. virtio-serial driver based on new virtio framework;
4. virtio-rng driver based on new virtio framework;
5. virtio-net driver based on new virtio framework
   (IOB Offload implementation);
6. virtio-blk driver based on new virtio framework;
7. Remove the old virtio mmio framework, the old framework only
   support mmio transport layer, and the new framwork support
   more transport layer and this commit has implemented all the
   old virtio drivers;
8. Refresh the the qemu-arm64 and qemu-riscv virtio related
   configs, and update its README.txt;

New virtio-net driver has better performance
Compared with previous virtio-mmio-net:
|                        | master/-c | master/-s | this/-c | this/-s |
| :--------------------: | :-------: | :-------: | :-----: | :-----: |
| qemu-armv8a:netnsh     |  539Mbps  |  524Mbps  | 906Mbps | 715Mbps |
| qemu-armv8a:netnsh_smp |  401Mbps  |  437Mbps  | 583Mbps | 505Mbps |
| rv-virt:netnsh         |  487Mbps  |  512Mbps  | 760Mbps | 634Mbps |
| rv-virt:netnsh_smp     |  387Mbps  |  455Mbps  | 447Mbps | 502Mbps |
| rv-virt:netnsh64       |  602Mbps  |  595Mbps  | 881Mbps | 769Mbps |
| rv-virt:netnsh64_smp   |  414Mbps  |  515Mbps  | 491Mbps | 525Mbps |
| rv-virt:knetnsh64      |  515Mbps  |  457Mbps  | 606Mbps | 540Mbps |
| rv-virt:knetnsh64_smp  |  308Mbps  |  389Mbps  | 415Mbps | 474Mbps |
Note: Both CONFIG_IOB_NBUFFERS=64, using iperf command, all in Mbits/sec
      Tested in QEMU 7.2.2

Signed-off-by: wangbowen6 <wangbowen6@xiaomi.com>
Signed-off-by: Zhe Weng <wengzhe@xiaomi.com>
2023-08-10 03:39:39 +08:00