zhanghongyu
03e220a271
bcm43xxx: revert part of the previous upstream code
...
Revert WPA failure reason codes to the previous community version
Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2023-09-24 01:55:54 +08:00
Shanmin Zhang
582e0ab51f
goldfish: add goldfish sensors driver
...
Implemented Goldfish Sensors:
Accelerometer
Gyroscope
MagneticField
AmbientTemperature
Proximity
Light
Pressure
RelativeHumidity
MagneticFieldUncalibrated
GyroscopeFieldUncalibrated
HeartRate
Unimplemented Goldfish Sensors:
(sensor type is not defined nuttx)
Orientation
HingeAngle0
HingeAngle1
HingeAngle2
WristTilt
Verification:
uorb_listener -r 1 sensor_accel
uorb_listener -r 1 sensor_mag
uorb_listener -r 1 sensor_gyro
uorb_listener -r 1 sensor_prox
uorb_listener -r 1 sensor_light
uorb_listener -r 1 sensor_humi
uorb_listener -r 1 sensor_baro
uorb_listener -r 1 sensor_temp
uorb_listener -r 1 sensor_hrate
Signed-off-by: Shanmin Zhang <zhangshanmin@xiaomi.com>
2023-09-23 15:20:25 +08:00
raiden00pl
0e01836f09
serial: add an option that selects uart rpmsg as console
2023-09-22 19:46:26 +08:00
SPRESENSE
7f574210a7
drivers:alt1250: Correspond to shutdown
...
ALT1250 driver to support shutdown.
2023-09-22 13:51:28 +08:00
wanggang26
e930476b4b
enable O_CLOEXEC explicit
...
Signed-off-by: wanggang26 <wanggang26@xiaomi.com>
2023-09-22 13:51:00 +08:00
dulibo1
b57e43b4d0
clk:fix some issues when use rpmsg clk
...
1.check the rpmsg name when clk_register.
2.clk_get rpmsg clk print error:
clk/clk.c:1231:3: runtime error: null pointer passed as argument 2, which is declared to never be null
3.fix some function miss keyword FAR.
4.clk_disable_unused may disable rpmsg clk which disable the clk that maybe used by others
Signed-off-by: dulibo1 <dulibo1@xiaomi.com>
2023-09-22 08:47:23 +08:00
dulibo1
2db471fab3
regulator:fix some issues when use rpmsg
...
1.client get the regualtor which is enabled by server, will disable the regualtor.
2.regulator_rpmsg_server_unbind will disable regualtor which maybe used by other client.
3.regulator_rpmsg_server_unbind will be deadloop when the regulator is always_on;
4.regulator_rpmsg_client_destroy does not match server cpu name,may destory by stop other rptun dev
Signed-off-by: dulibo1 <dulibo1@xiaomi.com>
2023-09-21 19:41:34 -04:00
dulibo1
da1cd59f35
regualtor:fix regulator_register check rpmsg regulator which leads to recursion
...
Signed-off-by: dulibo1 <dulibo1@xiaomi.com>
2023-09-21 19:41:34 -04:00
wanggang26
db2f204cc4
mmcsd: support dump cid and csd with mmc-utils
...
Signed-off-by: wanggang26 <wanggang26@xiaomi.com>
2023-09-21 22:40:39 +08:00
raiden00pl
0b00a02f81
sensors: add suffix _uorb to all sensors that use the new sensor framework
...
This'll make it easier to identify sensors supporting the new sensor approach
2023-09-21 20:30:08 +08:00
SPRESENSE
a3d17a18a7
drivers/modem/alt1250: Fix bug that errno was not converted correctly
...
Fix bug that errno was not converted correctly.
2023-09-21 13:54:21 +03:00
SPRESENSE
125f4a2ad0
drivers/modem/alt1250: Fix bug that modem version could not be taken
...
Fix bug that modem version could not be taken.
2023-09-21 17:44:12 +08:00
zhanghongyu
9267dbc7c2
bcm_driver: revert packed attribute for scan structure
...
These structures need to be aligned with the firmware, packed_struct will cause the scan information from Wi-Fi firmware not to be parsed by broadcom Wi-Fi driver. Therefore, we need to remove the packed_struct of the structure associated with the scan information.
Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2023-09-21 14:03:12 +08:00
dongjiuzhu1
c22646c0d4
driver/sensor: Solve the busy loop problem caused by sampling problems
...
Solve the problem that when a user modifies the sampling rate,
the difference between the generation and the mainline generation
may be greater than the own sampling interval.
After this problem occurs, sensor_is_update() will continue to
return true, resulting in a busy loop in the upper-layer application,
so, need update user generation according to mainline generation.
Signed-off-by: dongjiuzhu1 <dongjiuzhu1@xiaomi.com>
2023-09-20 23:09:56 +03:00
dongjiuzhu1
93b2a3744f
driver/spi: call bind and unbind when user open or close to save power
...
Signed-off-by: dongjiuzhu1 <dongjiuzhu1@xiaomi.com>
2023-09-20 23:08:36 +03:00
chao.an
76dfffe834
wireless/bcm43xxx: fix nxstyle issue
...
Signed-off-by: chao.an <anchao@xiaomi.com>
2023-09-21 01:36:21 +08:00
chao.an
ff2b87c298
wireless/bcm43xxx: add Packet Traffic Arbitration Priority support
...
For Bluetooth wifi co-existence
Signed-off-by: chao.an <anchao@xiaomi.com>
2023-09-21 01:36:21 +08:00
hujun5
1aa42cc7d2
vnc_updater: use [enter|leave]_critical_section replace sched_[un]lock
...
sched_[un]lock can not prohibit pre-emption in smp
Signed-off-by: hujun5 <hujun5@xiaomi.com>
2023-09-21 00:57:51 +08:00
chao.an
43dd6836f5
wireless/bcm43xxx: correct beacon loss behavior
...
Signed-off-by: chao.an <anchao@xiaomi.com>
2023-09-21 00:39:40 +08:00
Shanmin Zhang
9b68971853
goldfish: add goldfish gps driver
...
Verification:
uorb_listener -r 1 sensor_gps
[ 18.240000] [13] [ INFO] [ap]
Mointor objects num:2
[ 18.240000] [13] [ INFO] [ap] object_name:sensor_gps, object_instance:0
[ 18.240000] [13] [ INFO] [ap] object_name:sensor_gps, object_instance:1
[ 18.240000] [13] [ ALERT] [ap] period_us = 1000000
[ 19.010000] [13] [ INFO] [ap] sensor_gps: timestamp: 19010000 (0 us ago) time_utc: 1689601925 latitude: 37.4210 longitude: -121.9150
[ 19.010000] [13] [ INFO] [ap] sensor_gps: altitude: 0.0000 altitude_ellipsoid: 0.0000 ground_speed: 145.3254 course: 166.2700
[ 19.010000] [13] [ INFO] [ap] sensor_gps: eph: nan epv: nan hdop: nan vdop: nan
[ 20.020000] [13] [ INFO] [ap] sensor_gps: timestamp: 20020000 (0 us ago) time_utc: 1689601926 latitude: 37.4210 longitude: -121.9150
[ 20.020000] [13] [ INFO] [ap] sensor_gps: altitude: 0.0000 altitude_ellipsoid: 0.0000 ground_speed: 145.3254 course: 166.2700
[ 20.020000] [13] [ INFO] [ap] sensor_gps: eph: nan epv: nan hdop: nan vdop: nan
[ 21.010000] [13] [ INFO] [ap] sensor_gps: timestamp: 21010000 (0 us ago) time_utc: 1689601927 latitude: 37.4210 longitude: -121.9150
[ 21.010000] [13] [ INFO] [ap] sensor_gps: altitude: 0.0000 altitude_ellipsoid: 0.0000 ground_speed: 145.3254 course: 166.2700
[ 21.010000] [13] [ INFO] [ap] sensor_gps: eph: nan epv: nan hdop: nan vdop: nan
[ 22.020000] [13] [ INFO] [ap] sensor_gps: timestamp: 22020000 (0 us ago) time_utc: 1689601928 latitude: 37.4210 longitude: -121.9150
[ 22.020000] [13] [ INFO] [ap] sensor_gps: altitude: 0.0000 altitude_ellipsoid: 0.0000 ground_speed: 145.3254 course: 166.2700
[ 22.020000] [13] [ INFO] [ap] sensor_gps: eph: nan epv: nan hdop: nan vdop: nan
[ 23.010000] [13] [ INFO] [ap] sensor_gps: timestamp: 23010000 (0 us ago) time_utc: 1689601929 latitude: 37.4210 longitude: -121.9150
[ 23.010000] [13] [ INFO] [ap] sensor_gps: altitude: 0.0000 altitude_ellipsoid: 0.0000 ground_speed: 145.3254 course: 166.2700
[ 23.010000] [13] [ INFO] [ap] sensor_gps: eph: nan epv: nan hdop: nan vdop: nan
...
Signed-off-by: Shanmin Zhang <zhangshanmin@xiaomi.com>
2023-09-21 00:38:14 +08:00
Jani Paalijarvi
c8540a1f9b
drivers/net/rpmsgdrv.c: Improve init error handling
...
Signed-off-by: Jani Paalijarvi <jani.paalijarvi@unikie.com>
2023-09-20 19:23:14 +08:00
Jani Paalijarvi
999970b820
drivers/net/rpmsgdrv.c: Take netdev_register() return value into account
...
Signed-off-by: Jani Paalijarvi <jani.paalijarvi@unikie.com>
2023-09-20 19:23:14 +08:00
zhanghongyu
398734500e
wifi: parse channel from IE when ctl_ch is 0
...
Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2023-09-20 14:26:41 +08:00
zhanghongyu
537975656c
wifi: Add handle type for disconnecting event
...
Some disconnected events will be missed
Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2023-09-20 10:07:40 +08:00
wanggang26
fa744e24a3
mmcsd: update cid reg layout
...
refer spec: https://www.jedec.org/sites/default/files/docs/JESD84-B51.pdf
Signed-off-by: wanggang26 <wanggang26@xiaomi.com>
2023-09-20 00:42:30 +08:00
yintao
f3c9a8643b
nuttx: change RPTUNIOC_START and RPTUNIOC_STOP to synchronous
...
Support quit remote when server poweroff
Signed-off-by: yintao <yintao@xiaomi.com>
2023-09-20 00:42:02 +08:00
ligd
1f9fb5fce2
rptun: add rptun_update_rx() when device_created()
...
Signed-off-by: ligd <liguiding1@xiaomi.com>
2023-09-20 00:42:02 +08:00
ligd
378470f611
add remote poweroff support
...
Signed-off-by: yintao <yintao@xiaomi.com>
2023-09-20 00:42:02 +08:00
yangsen5
e0873c5a48
drivers/video: Fix crash caused by priv->capture_cb = null
...
When the upper layer calls goldfish_camera_data_uninit, priv->capture_cb=NULL, but when there is data transmission in goldfish_camera_thread, priv->capture_cb will be called, which will cause a crash.
Signed-off-by: yangsen5 <yangsen5@xiaomi.com>
2023-09-20 00:34:54 +08:00
sunkun3
219677cdae
rndis: Fixed rndis assert issue when calling composite_uninitlize
...
Signed-off-by: sunkun3 <sunkun3@xiaomi.com>
2023-09-19 07:51:49 +02:00
Xiang Xiao
635d578a73
drivers/sensor: Remove the selection of UORB from Kconfig
...
since the driver doesn't depend on userspace library(uORB) at all
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-09-19 11:27:47 +08:00
zhengshaobo1
6e6ba062fd
clock flags add CLK_OPS_PARENT_ENABLE, parents need enable during gate/ungate, set rate and re-parent
...
Signed-off-by: zhengshaobo1 <zhengshaobo1@xiaomi.com>
2023-09-19 10:34:48 +08:00
zhengshaobo1
be767dde01
vela fs procfs add clock procfs entry
...
procfs enrty add clock feature procfs operations
Signed-off-by: zhengshaobo1 <zhengshaobo1@xiaomi.com>
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-09-19 10:34:48 +08:00
Xiang Xiao
4d2cc2ab4d
supply/regulator: Refine rpmsg regulator
...
1.Change priv to client or server
2.Allocate memory for name in regulator_rpmsg_get
3.Lock/unlock regulator_list in regulator_rpmsg_server_s
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-09-19 10:33:09 +08:00
yinshengkai
1d8e69700f
drivers/serial: add ram uart driver
...
It uses the memory block as the serial communication medium, which can communicate between different processes or different CPUs
Using the following configuration, the cross-core communication rate of 200MHz cortex-M55 is about 461KB/s
RAM_UART_BUFSIZE=1024
RAM_UART_POLLING_INTERVAL=100
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-09-19 09:41:07 +08:00
yinshengkai
1d9097f1df
drivers/serial: unmodify head and tail pointers
...
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2023-09-19 09:41:07 +08:00
chao an
5026a96cfa
nxstyle: cleanup UTF-8 Unicode to ASCII
...
Signed-off-by: chao an <anchao@xiaomi.com>
2023-09-18 11:54:17 -04:00
Daniel Appiagyei
5bfda12634
c++ compatibility: rename reserved c++ keywords 'public' and 'this'
2023-09-16 19:45:02 +08:00
dulibo1
ac62a08ac9
support pm runtime base function
...
Signed-off-by: dulibo1 <dulibo1@xiaomi.com>
2023-09-16 14:44:08 +08:00
dongjiuzhu1
8ababfc310
usbdev/mtp: support mtp class driver
...
Signed-off-by: dongjiuzhu1 <dongjiuzhu1@xiaomi.com>
2023-09-16 14:40:08 +08:00
jturnsek
4407aa148e
Fixing row_size calculation when bpp is equal 1
2023-09-16 14:37:19 +08:00
jturnsek
6840b4444b
Adding Byte-Per-Pixel Memory model option to memlcd
2023-09-16 14:34:32 +08:00
Petro Karashchenko
dbc37a0165
nuttx: fix nxstyle issues
...
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-09-16 14:17:47 +08:00
Petro Karashchenko
1c9fe095bf
drivers/ramdisk: add missing 'FAR'
...
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-09-16 14:17:47 +08:00
liushuai25
10fce11e19
After turning on the system by power button, the first press of the power button is ineffective.
...
Signed-off-by: liushuai25 <liushuai25@xiaomi.com>
Co-authored-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2023-09-16 08:31:44 +03:00
SPRESENSE
1b1b1a025d
usbdev: Fix build error with BOARD_USBDEV_SERIALSTR
2023-09-15 13:34:06 +08:00
Zhe Weng
e4721cef5c
usrsock_rpmsg_server: Add net_lock to combine get_tx_payload and recvfrom in recvfrom_handler
...
A dead lock may happen before this patch:
rptun thread (usrsock_rpmsg_recvfrom_handler):
Gets all tx payload but waiting net_lock in psock_recvfrom
net driver thread (higher priority):
Receives a packet, holding net_lock, calling usrsock_rpmsg_send_event
But no tx buffer left, so rpmsg_send blocks, and won't release net_lock
In short:
Rptun: Hold all `tx_payload_buffer` -> want `net_lock`
Driver: Hold `net_lock` -> want `tx_payload_buffer`
This patch use net_lock to combine get_tx_payload and recvfrom together,
then:
- If it's waiting net_lock, tx payload will not be held, other threads
may get tx buffer and do their work.
- If net_lock is got, it won't be disturbed before finish receiving,
then tx payload won't have chance to be blocked before releasing.
Signed-off-by: Zhe Weng <wengzhe@xiaomi.com>
2023-09-14 14:32:40 +08:00
wanggang26
dcadd87919
pm: fix issue that system crash when passed invalid relpath value
...
Signed-off-by: wanggang26 <wanggang26@xiaomi.com>
2023-09-13 21:47:27 +08:00
simbit18
b3973496cd
Fix Kconfig style
...
Remove spaces from Kconfig
Add comments
2023-09-13 21:39:49 +08:00
Zhe Weng
33da959fbc
usrsock_rpmsg_server: Clear revents for POLLHUP and POLLERR
...
Note:
tcp_poll_eventhandler have logic after poll_notify, if we teardown poll
inside poll callback without clearing revents, use-after-free will
happen.
Signed-off-by: Zhe Weng <wengzhe@xiaomi.com>
2023-09-12 22:12:31 +08:00