Łukasz Stelmach [Thu, 8 Apr 2021 13:36:04 +0000 (15:36 +0200)]
logger-test: more intensive tests
Send enough data to logger to fill the whole ring buffer.
Test assembly of large messages without newline characters.
Check return value from write(2).
Remove some dead code.
Change-Id: I165458f5c7831bd925164aa087f28fd319c9872f
Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
Łukasz Stelmach [Wed, 14 Apr 2021 15:50:51 +0000 (17:50 +0200)]
logger: introduce struct logger_set_tag
Introduce dedicated structure for LOGGER_SET_TAG ioctl,
instead of packing and unpacking arguments by hand.
Change-Id: Ic3399ab37f55ba2b8a9a976f8c9495fc487fe7f3
Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
Łukasz Stelmach [Fri, 19 Mar 2021 14:20:06 +0000 (15:20 +0100)]
logger: move logger.h to uapi
Move logger.h to uapi so it can be exported for userland
software to use.
Change-Id: I64dca69f3442edc246562485b0b29b43615ae881
Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
Łukasz Stelmach [Tue, 13 Apr 2021 10:24:38 +0000 (12:24 +0200)]
logger: return amount of data written to stdio
Return amount of data written by a process to a logger via STDIO
interface.
Change-Id: I9c77a312d09f3d796a7ec64d5909af193bcc8bc2
Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
Łukasz Stelmach [Fri, 9 Apr 2021 15:20:07 +0000 (17:20 +0200)]
logger: fix temporary buffer handling
Prevent writing beyond temporary buffer and improve accumulation of data
before receiving a newline character or filling the buffer.
Change-Id: I8e0591c90914dbd4c2addde4247157831fa4843a
Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
Łukasz Stelmach [Fri, 9 Apr 2021 14:59:56 +0000 (16:59 +0200)]
logger: adapt access mode checks
Allow setting the tag and the priority only for files opened O_WRONLY.
Change-Id: Icc9d7a8eb96f8f1b1aa00717aae1f32f7a2e52e4
Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
Łukasz Stelmach [Thu, 8 Apr 2021 12:09:24 +0000 (14:09 +0200)]
logger: Fix incorrect buffer access when writing data
Fix crash caused by accessing memory beyond log->buffer
Change-Id: I528b62e34e9fb5f92f62f6b218718e15cd5f7d31
Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
Łukasz Stelmach [Mon, 15 Feb 2021 14:41:27 +0000 (15:41 +0100)]
logger: testing tool for STDIO logger
Change-Id: I029a7def836b317a4e059c7a56301e169910a830
Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
Łukasz Stelmach [Fri, 12 Feb 2021 17:41:09 +0000 (18:41 +0100)]
logger: accept untagged log entries
Add support for writing untagged log messages to /dev/log_* nodes. The
logger shall accept untagget messages after setting the tag and
the priority with appropriate ioctl() commands for particular file
descriptors.
Change-Id: I02bd7bfd843eaf316692413a48747009c42756f6
Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
Łukasz Stelmach [Mon, 29 Mar 2021 08:35:37 +0000 (10:35 +0200)]
kdbus: build and package kdbus-tests
Change-Id: Icfcecc2780e6c5cdddaad0440b731ebb9dc49446
Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
Konrad Lipinski [Wed, 11 Sep 2019 13:42:10 +0000 (15:42 +0200)]
kdbus: test suite changed to common format
This commit adapts the kdbus test suite to use with
dbus-integration-tests.
Change-Id: Ifee21253f4e3c732b27517a0c566d4b9a569d5af
Origin: commit:
2c0f308e6d963987fcb4e5754f504028d4511629
Signed-off-by: Adrian Szyndela <adrian.s@samsung.com>
Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
Łukasz Stelmach [Fri, 26 Mar 2021 21:47:17 +0000 (22:47 +0100)]
ARM/ARM64: Enable KDBUS in tizen defconfigs
Change-Id: Ib1680e530acf3cb9161cdb53b5db5ef87f51df8c
Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
Łukasz Stelmach [Fri, 26 Mar 2021 21:41:29 +0000 (22:41 +0100)]
kdbus: porting to to 4.19
The following changes were made to adapt kdbus driver to 4.19 kernel
- use memfd_fcntl() instead of shmem_get_seals()
Change-Id: Iff24cd3c429310c3af748657a24a5e35db738635
Fixes:
5aadc431a593 ("shmem: rename functions that are memfd-related")
Fixes:
5d752600a8c3 ("mm: restructure memfd code")
Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
Łukasz Stelmach [Mon, 21 Dec 2020 11:40:27 +0000 (12:40 +0100)]
kdbus: Revert "fs: unexport poll_schedule_timeout"
This reverts commit
8f546ae1fc5ce8396827d4868c7eee1f1cc6947a.
Change-Id: I5429471eeb092c55a50e37c0b642d50d69daebc7
Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
Adrian Szyndela [Wed, 11 Sep 2019 13:34:33 +0000 (15:34 +0200)]
kdbus: porting to 4.14
This commit makes kdbus driver working with kernel 4.14.
It also enabled compilation of the driver if enabled in config.
The list of changes needed to make it compile with kernel 4.14:
- Add missing includes for <linux/cred.h>
- put inode_lock()/inode_unlock() in place of explicit mutex locking
- replace CURRENT_TIME with proper call to current_time()
- replace PAGE_CACHE_* with PAGE_*
- replace GFP_TEMPORARY with GFP_KERNEL
- use kvecs for kernel memory, iovec for user memory instead of only iovec
for both
- fix usage of task_cgroup_path()
- replace GROUP_AT usage with 'gid' field dereference
- add 0 as an argument to init_name_hash
- add 0 as flags as an argument to vfs_iter_write
- replace __vfs_read with kernel_read to allow compilation into module
Change-Id: Ifed3a6d3a37082a900a64316af1c8a21ab30e84e
Origin: commit:
846051292431cc81adb852c2b0cbbfddac4a3d48
Signed-off-by: Adrian Szyndela <adrian.s@samsung.com>
Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
Adrian Szyndela [Fri, 9 Sep 2016 11:35:49 +0000 (13:35 +0200)]
kdbus: the driver, original and non-working
[based on commit
216823ac83c0ab89348e2ed6f66179f53626586e]
Introduce the kdbus driver again. This driver worked previously
on kernel 4.1. This is the source code taken from the working driver.
It is non-working and disabled. It is a base for porting.
The documentation is moved from Documentation to ipc/kdbus/Documentation.
The references to kdbus source code are commented out or removed in Makefiles.
Original authors of the files are those from commit
216823ac83c0ab8934.
Cherry-picked from 5.4 commit
e2d621efdb4f1c1a6e782121d95b62ea249828f2
Change-Id: If8baeb585b5ecedd4286553405c3a8d24fed9c3a
Signed-off-by: Adrian Szyndela <adrian.s@samsung.com>
Signed-off-by: Hyotaek Shim <hyotaek.shim@samsung.com>
Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
Łukasz Stelmach [Mon, 4 Jan 2021 19:23:41 +0000 (20:23 +0100)]
spec: set CONFIG_LOCALVERSION
Set CONFIG_LOCALVERSION insetad of EXTRAVERSION in Makefile to carry
information about the platform variant.
Change-Id: I72986cb618b998983f1e9f6eccba7d6e4603248f
Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
Łukasz Stelmach [Fri, 26 Mar 2021 14:50:37 +0000 (15:50 +0100)]
spec: support gbs(1) incremental builds
gbs(1) enable incremental builds that are significantly faster, hoewever,
spec files need some adjustments.
+ You can't use -n <name> with %setup
+ use rsync(1) instead of cp(1)+find(1) to copy devel files
Other changes are:
+ add _smp_mflags to make(1) things faster
Change-Id: I18c47b59b1bfef17501ab57f39f93d7185592f13
Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
Łukasz Stelmach [Fri, 26 Mar 2021 14:19:20 +0000 (15:19 +0100)]
script: adjust ccache support
Change-Id: Ia37a450bccf93ddf3daaca442be4d221df0d4036
Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
Łukasz Stelmach [Fri, 26 Mar 2021 14:15:20 +0000 (15:15 +0100)]
script: Reformat to align with build-rpi4.sh
Reformat the script to bring it into alignment with build-rpi4.sh for
easier maintenance.
Change-Id: Ie97a1acc28486e62630062587a30689a9f19e085
Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
Łukasz Stelmach [Fri, 26 Mar 2021 14:02:18 +0000 (15:02 +0100)]
script: Detect number of CPUs
Automatically determine the number of parallel make(1) processes to run.
Change-Id: I0ce778e5c15ceb8cf80bbfc2f4bb58c937630ba3
Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
Jaehoon Chung [Thu, 11 Mar 2021 04:57:34 +0000 (13:57 +0900)]
packaging: not delete the vmlinux file to debug
To debug with T32, it needs to use vmlinux file.
Incldue its file in devel package.
Change-Id: Ib01d80a99e08e99ecbdaa3a6e0787ac5dbe0e372
Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
Jaehoon Chung [Wed, 17 Feb 2021 00:51:59 +0000 (09:51 +0900)]
ARM/ARM64: defconfig: disable SECURITY_SMACK_NETFILTER config
Disable SECURITY_SMACK_NETFILTER configuration.
Change-Id: Idcc1175672ea2c86c232d834589c1a7c364636aa
Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
Seung-Woo Kim [Mon, 25 Jan 2021 07:35:08 +0000 (16:35 +0900)]
ARM: tizen_bcm2709_defconfig: Enable OVERLAY_FS
Enable CONFIG_OVERLAY_FS for tizen application space.
Change-Id: I79add9d8b79281074ae1dd1d12a9c65fa422410b
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Mon, 25 Jan 2021 07:34:33 +0000 (16:34 +0900)]
ARM64: tizen_bcmrpi3_defconfig: Enable OVERLAY_FS
Enable CONFIG_OVERLAY_FS for tizen application space.
Change-Id: I8c61e997c504467c0204d6e29b1c1f3ebac1c379
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Wed, 28 Oct 2020 09:19:20 +0000 (18:19 +0900)]
ARM64: configs: tizen_bcmrpi3_defconfig: Enable BCM_VCIO
Enable userland broadcom mailbox support, CONFIG_BCM_VCIO, as like
32bit config.
Change-Id: Ic0e33aaa2ed4040db57e8e48e2dabb2197cf9e4e
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Fri, 21 Aug 2020 01:10:27 +0000 (10:10 +0900)]
Revert "WORKAROUND: security: smack: Allow ptracing even processes in onlycap set"
This reverts commit
718567d336d0b0943385905bb12707552d8bef66.
Now crash-worker has System::Privileged privilege, so not anymore
ptrace related workaround is necessary. So revert the workaround.
Change-Id: I42b535e4152eb742df011a5a08324764b49f989a
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Karol Lewandowski [Fri, 7 Aug 2020 11:49:30 +0000 (13:49 +0200)]
WORKAROUND: security: smack: Allow ptracing even processes in onlycap set
Change-Id: I708d19703da0f1b83950454fda1362bec7369b5c
Signed-off-by: Karol Lewandowski <k.lewandowsk@samsung.com>
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Jaehoon Chung [Mon, 3 Aug 2020 06:41:28 +0000 (15:41 +0900)]
Revert "brcmfmac: move configuration of probe request IEs"
This reverts commit
bd99a3013bdc00f8fc7534c657b39616792b4467.
It doesn't find any p2p-device with wpa_supplicant on Tien.
- After reverted this, it's working fine.
Change-Id: I1cd77e65ad17078370116473dd46adc7338d6695
Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
Seung-Woo Kim [Fri, 17 Jul 2020 05:03:38 +0000 (14:03 +0900)]
ARM64: configs: tizen_bcmrpi3_defconfig: Enable FUSE_FS
Tizen requires CONFIG_FUSE_FS for user space filesystem. Enable
the option.
Change-Id: Ia4eefdcd95b5be4944a9717e69a4ce2deb31a081
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Fri, 17 Jul 2020 05:02:44 +0000 (14:02 +0900)]
ARM: configs: tizen_bcm2709_defconfig: Enable FUSE_FS
Tizen requires CONFIG_FUSE_FS for user space filesystem. Enable
the option.
Change-Id: Icf66feb085fee5ab30e3b680d1914a51f276d9bd
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Jaehoon Chung [Thu, 25 Jun 2020 07:02:27 +0000 (16:02 +0900)]
ARM: configs: tizen_bcm2709: revert BLK_DEV_RAM_COUNT to 16
Revert BLK_DEV_RAM_COUNT to 16 - default value.
Becaues there is timing issue about booting fail, use default value.
Change-Id: Ida3985e9a48863abbc2bd14476edb146c3f5744f
Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
Jaehoon Chung [Thu, 25 Jun 2020 07:01:33 +0000 (16:01 +0900)]
ARM64: configs: tizen_bcmrpi3: revert BLK_DEV_RAM_COUNT to 16
Revert BLK_DEV_RAM_COUNT to 16 - default value.
Becaues there is timing issue about booting fail, use default value.
Change-Id: I1bec8f42fc719522510971ad5ec25512e57ee8aa
Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
Jaehoon Chung [Mon, 22 Jun 2020 07:14:37 +0000 (16:14 +0900)]
ARM: configs: tizen_bcm2709: change BLK_DEV_RAM_SIZE to 32MB
Change BLK_DEV_RAM_SIZE from 12MB to 32MB.
And also change BLK_DEV_RAM_COUNT from 16 to 2.
It doesn't need to keep /dev/ram0-16.
Change-Id: If6acb3813061827a260e5b6414a34e06cfc0965b
Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
Jaehoon Chung [Mon, 22 Jun 2020 07:13:46 +0000 (16:13 +0900)]
ARM64: configs: tizen_bcmrpi3: change BLK_DEV_RAM_SIZE to 32MB
Change BLK_DEV_RAM_SIZE from 12MB to 32MB.
And also change BLK_DEV_RAM_COUNT from 16 to 2.
It doesn't need to keep /dev/ram0-16.
Change-Id: I598dba4abc102a7ba51f5419ad6871875b73165c
Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
Seung-Woo Kim [Fri, 17 Apr 2020 03:26:21 +0000 (12:26 +0900)]
packaging: Add build perf with unwind call-graph support
To support perf unwind call-graph, add BuildRequires for unwind,
dw, elfutils and other related devel packages. Also add definition
to remove not necessary perl dependency
Change-Id: I8e94ec4642026841255bbec08ae3dea2a8f5b531
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Ravi Bangoria [Tue, 11 Jun 2019 03:01:09 +0000 (08:31 +0530)]
perf version: Fix segfault due to missing OPT_END()
'perf version' on powerpc segfaults when used with non-supported
option:
# perf version -a
Segmentation fault (core dumped)
Fix this.
Signed-off-by: Ravi Bangoria <ravi.bangoria@linux.ibm.com>
Reviewed-by: Kamalesh Babulal <kamalesh@linux.vnet.ibm.com>
Tested-by: Mamatha Inamdar <mamatha4@linux.vnet.ibm.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Kamalesh Babulal <kamalesh@linux.vnet.ibm.com>
Link: http://lkml.kernel.org/r/20190611030109.20228-1-ravi.bangoria@linux.ibm.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
[sw0312.kim: cherry-pick mainline commit
916c31fff946 to fix possible seg.fault in Tizen armv7l]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Change-Id: If19720350e2992d1f5e58711f1f708a4d4ec5683
Rafał Miłecki [Mon, 11 Feb 2019 22:04:54 +0000 (23:04 +0100)]
brcmfmac: support firmware reporting 160 MHz channels
So far 160 MHz channels were treated as 20 MHz ones which was breaking
support for 40/80 MHz due to the brcmf_construct_chaninfo() logic and
its assumptions.
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
[sw0312.kim: backport mainline commit
30519cbe339a to show more 5G channels properly]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Change-Id: I62ca12dfd97d0cd3233840d5b569e768dc4a1672
Seung-Woo Kim [Mon, 16 Mar 2020 10:09:40 +0000 (19:09 +0900)]
rpi3: config_64bit: boot from u-boot instead of spl
Now, Tizen does not support OPTEE by default, so u-boot-spl is not
required. Boot from u-boot instead of u-boot-spl.
Change-Id: Iadaee5290ede214b4f85487eea8e9151f9ea98f9
Ref: https://bugs.tizen.org/browse/TRE-2318
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Mon, 16 Mar 2020 10:08:19 +0000 (19:08 +0900)]
ARM64: tizen_bcmrpi3_defconfig: Disable OPTEE
Now, Tizen does not support OPTEE by default. Disable OPTEE config
options.
Change-Id: I424d38f42ad0e3199bd84517fb477dc212785be8
Ref: https://bugs.tizen.org/browse/TRE-2318
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Mon, 16 Mar 2020 10:06:53 +0000 (19:06 +0900)]
ARM: dts: bcm2710-rpi-3: Change build macro for optee
Now, Tizen does not support optee by default. Change build macro
for optee related nodes in default case.
Change-Id: Ib925414ba6fd96099ca984cc8b665263812b9538
Ref: https://bugs.tizen.org/browse/TRE-2318
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Junghoon Kim [Mon, 20 Jan 2020 06:28:38 +0000 (15:28 +0900)]
ARM64: tizen_bcmrpi3_defconfig: Disable RAID6_PQ_BENCHMARK
Skip the algorithm benchmarking process of RAID6 for the fast kernel
startup. The option is not crucial for the rpi boards.
Change-Id: I9c959bcf2bbb178e72bc4315a0734d8059ebd46b
Signed-off-by: Junghoon Kim <jhoon20.kim@samsung.com>
Junghoon Kim [Mon, 20 Jan 2020 06:24:43 +0000 (15:24 +0900)]
ARM: tizen_bcm2709_defconfig: Disable RAID6_PQ_BENCHMARK
Skip the algorithm benchmarking process of RAID6 for the fast kernel
startup. The option is not crucial for the rpi boards.
Change-Id: If0a4748febb2fad3349b4327624943bdf42454d4
Signed-off-by: Junghoon Kim <jhoon20.kim@samsung.com>
Daniel Verkamp [Mon, 12 Nov 2018 23:26:52 +0000 (15:26 -0800)]
lib/raid6: add option to skip algo benchmarking
This is helpful for systems where fast startup time is important.
It is especially nice to avoid benchmarking RAID functions that are
never used (for example, BTRFS selects RAID6_PQ even if the parity RAID
mode is not in use).
This saves 250+ milliseconds of boot time on modern x86 and ARM systems
with a dozen or more available implementations.
The new option is defaulted to 'y' to match the previous behavior of
always benchmarking on init.
Signed-off-by: Daniel Verkamp <dverkamp@chromium.org>
Signed-off-by: Shaohua Li <shli@fb.com>
[jhoon20.kim: backport from mainline for the fast kernel startup]
Change-Id: I38c270c413d60de65f27cf9c95d44bb2e2d07ac2
Signed-off-by: Junghoon Kim <jhoon20.kim@samsung.com>
Seung-Woo Kim [Mon, 6 Jan 2020 07:57:23 +0000 (16:57 +0900)]
ARM: configs: tizen_bcm2709_defconfig: Enable missing NETFILTER options for nether
To properly support nether rules, netfilter options are required
including udplite, raw, mangle and others. Enable the missing
NETFILTER options for nether.
Ref: nether rule in https://git.tizen.org/cgit/platform/core/security/nether/tree/conf/nether.rules?h=tizen
Change-Id: I7cb0b1f669e412540085a05fcbb95d5fc7afaffc
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Mon, 6 Jan 2020 07:54:58 +0000 (16:54 +0900)]
ARM64: configs: tizen_bcmrpi3_defconfig: Enable missing NETFILTER options for nether
To properly support nether rules, netfilter options are required
including udplite, raw, mangle and others. Enable the missing
NETFILTER options for nether.
Ref: nether rule in https://git.tizen.org/cgit/platform/core/security/nether/tree/conf/nether.rules?h=tizen
Change-Id: I9017da2dc9bc74a83488f8b74e843d2ff23395a2
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Mon, 6 Jan 2020 01:30:22 +0000 (10:30 +0900)]
ARM: configs: tizen_bcm2709_defconfig: Enable USB SERIAL drivers for modem
To support usb modem dongle and related devices, enable USB SERIAL
drivers and ppp network interface to support the modem.
Change-Id: I0f496f38e20f6816653dad354efde1519a54670c
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Mon, 6 Jan 2020 01:29:08 +0000 (10:29 +0900)]
ARM64: configs: tizen_bcmrpi3_defconfig: Enable USB SERIAL drivers for modem
To support usb modem dongle and related devices, enable USB SERIAL
drivers and ppp network interface to support the modem.
Change-Id: I3caf00b94edc0ad98ae95687bfc8d0b845413cfb
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Nathan Chancellor [Tue, 11 Jun 2019 17:19:32 +0000 (10:19 -0700)]
arm64: Don't unconditionally add -Wno-psabi to KBUILD_CFLAGS
commit
fa63da2ab046b885a7f70291aafc4e8ce015429b upstream.
This is a GCC only option, which warns about ABI changes within GCC, so
unconditionally adding it breaks Clang with tons of:
warning: unknown warning option '-Wno-psabi' [-Wunknown-warning-option]
and link time failures:
ld.lld: error: undefined symbol: __efistub___stack_chk_guard
>>> referenced by arm-stub.c:73
(/home/nathan/cbl/linux/drivers/firmware/efi/libstub/arm-stub.c:73)
>>> arm-stub.stub.o:(__efistub_install_memreserve_table)
in archive ./drivers/firmware/efi/libstub/lib.a
These failures come from the lack of -fno-stack-protector, which is
added via cc-option in drivers/firmware/efi/libstub/Makefile. When an
unknown flag is added to KBUILD_CFLAGS, clang will noisily warn that it
is ignoring the option like above, unlike gcc, who will just error.
$ echo "int main() { return 0; }" > tmp.c
$ clang -Wno-psabi tmp.c; echo $?
warning: unknown warning option '-Wno-psabi' [-Wunknown-warning-option]
1 warning generated.
0
$ gcc -Wsometimes-uninitialized tmp.c; echo $?
gcc: error: unrecognized command line option
‘-Wsometimes-uninitialized’; did you mean ‘-Wmaybe-uninitialized’?
1
For cc-option to work properly with clang and behave like gcc, -Werror
is needed, which was done in commit
c3f0d0bc5b01 ("kbuild, LLVMLinux:
Add -Werror to cc-option to support clang").
$ clang -Werror -Wno-psabi tmp.c; echo $?
error: unknown warning option '-Wno-psabi'
[-Werror,-Wunknown-warning-option]
1
As a consequence of this, when an unknown flag is unconditionally added
to KBUILD_CFLAGS, it will cause cc-option to always fail and those flags
will never get added:
$ clang -Werror -Wno-psabi -fno-stack-protector tmp.c; echo $?
error: unknown warning option '-Wno-psabi'
[-Werror,-Wunknown-warning-option]
1
This can be seen when compiling the whole kernel as some warnings that
are normally disabled (see below) show up. The full list of flags
missing from drivers/firmware/efi/libstub are the following (gathered
from diffing .arm64-stub.o.cmd):
-fno-delete-null-pointer-checks
-Wno-address-of-packed-member
-Wframe-larger-than=2048
-Wno-unused-const-variable
-fno-strict-overflow
-fno-merge-all-constants
-fno-stack-check
-Werror=date-time
-Werror=incompatible-pointer-types
-ffreestanding
-fno-stack-protector
Use cc-disable-warning so that it gets disabled for GCC and does nothing
for Clang.
Fixes:
ebcc5928c5d9 ("arm64: Silence gcc warnings about arch ABI drift")
Link: https://github.com/ClangBuiltLinux/linux/issues/511
Reported-by: Qian Cai <cai@lca.pw>
Acked-by: Dave Martin <Dave.Martin@arm.com>
Reviewed-by: Nick Desaulniers <ndesaulniers@google.com>
Signed-off-by: Nathan Chancellor <natechancellor@gmail.com>
Signed-off-by: Will Deacon <will.deacon@arm.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
[sw0312.kim: cherry-pick from stable linux-4.19.y commit
85a3b1ef969b for gcc 9 build]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Change-Id: I264a7663478de10d196d8550349098552fe02544
Dave Martin [Thu, 6 Jun 2019 10:33:43 +0000 (11:33 +0100)]
arm64: Silence gcc warnings about arch ABI drift
[ Upstream commit
ebcc5928c5d925b1c8d968d9c89cdb0d0186db17 ]
Since GCC 9, the compiler warns about evolution of the
platform-specific ABI, in particular relating for the marshaling of
certain structures involving bitfields.
The kernel is a standalone binary, and of course nobody would be
so stupid as to expose structs containing bitfields as function
arguments in ABI. (Passing a pointer to such a struct, however
inadvisable, should be unaffected by this change. perf and various
drivers rely on that.)
So these warnings do more harm than good: turn them off.
We may miss warnings about future ABI drift, but that's too bad.
Future ABI breaks of this class will have to be debugged and fixed
the traditional way unless the compiler evolves finer-grained
diagnostics.
Signed-off-by: Dave Martin <Dave.Martin@arm.com>
Signed-off-by: Will Deacon <will.deacon@arm.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
[sw0312.kim: cherry-pick from stable linux-4.19.y commit
71d019a6dae9 for gcc 9 build]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Change-Id: I6a6ca56261860468207555d869f5a90882565c4b
Miguel Ojeda [Thu, 23 May 2019 12:45:35 +0000 (14:45 +0200)]
tracing: Silence GCC 9 array bounds warning
commit
0c97bf863efce63d6ab7971dad811601e6171d2f upstream.
Starting with GCC 9, -Warray-bounds detects cases when memset is called
starting on a member of a struct but the size to be cleared ends up
writing over further members.
Such a call happens in the trace code to clear, at once, all members
after and including `seq` on struct trace_iterator:
In function 'memset',
inlined from 'ftrace_dump' at kernel/trace/trace.c:8914:3:
./include/linux/string.h:344:9: warning: '__builtin_memset' offset
[8505, 8560] from the object at 'iter' is out of the bounds of
referenced subobject 'seq' with type 'struct trace_seq' at offset
4368 [-Warray-bounds]
344 | return __builtin_memset(p, c, size);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
In order to avoid GCC complaining about it, we compute the address
ourselves by adding the offsetof distance instead of referring
directly to the member.
Since there are two places doing this clear (trace.c and trace_kdb.c),
take the chance to move the workaround into a single place in
the internal header.
Link: http://lkml.kernel.org/r/20190523124535.GA12931@gmail.com
Signed-off-by: Miguel Ojeda <miguel.ojeda.sandonis@gmail.com>
[ Removed unnecessary parenthesis around "iter" ]
Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
[sw0312.kim: cherry-pick stable linux-4.19.y commit
c493ead38adb for gcc 9 build]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Change-Id: I660c183206836972e5e39ff54ccfdd23517b5295
Linus Torvalds [Wed, 1 May 2019 18:07:40 +0000 (11:07 -0700)]
gcc-9: don't warn about uninitialized variable
commit
cf676908846a06443fa5e6724ca3f5dd7460eca1 upstream.
I'm not sure what made gcc warn about this code now. The 'ret' variable
does end up initialized in all cases, but it's definitely not obvious,
so the compiler is quite reasonable to warn about this.
So just add initialization to make it all much more obvious both to
compilers and to humans.
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
[sw0312.kim: cherry-pick from stable linux-4.19.y commit
a152a7b411a5 for gcc 9 build]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Change-Id: I9ffd18114904d32ebb631680c7ac40d9771771c2
Linus Torvalds [Wed, 1 May 2019 18:05:41 +0000 (11:05 -0700)]
gcc-9: silence 'address-of-packed-member' warning
commit
6f303d60534c46aa1a239f29c321f95c83dda748 upstream.
We already did this for clang, but now gcc has that warning too. Yes,
yes, the address may be unaligned. And that's kind of the point.
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
[sw0312.kim: cherry-pick from stable linux-4.19.y commit
76343a1363f8 for gcc 9 build]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Change-Id: Ia29a74ee9de68e0518c46e7cc0affad1f07d5f10
Arnaldo Carvalho de Melo [Tue, 30 Oct 2018 19:50:08 +0000 (16:50 -0300)]
tools include uapi: Update linux/mmap.h copy
To pick up the changes from:
20916d4636a9 ("mm/hugetlb: add mmap() encodings for 32MB and 512MB page sizes")
That do not entail changes in in tools, this just shows that we have to
consider bits [26:31] of flags to beautify that in tools like 'perf
trace'
This silences this perf build warning:
Warning: Kernel ABI header at 'tools/include/uapi/linux/mman.h' differs from latest version at 'include/uapi/linux/mman.h'
diff -u tools/include/uapi/linux/mman.h include/uapi/linux/mman.h
Cc: Anshuman Khandual <anshuman.khandual@arm.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Link: https://lkml.kernel.org/n/tip-3rvc39lon93kgt5pl31d8g4x@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
[sw0312.kim: cherry-pick mainline commit
685626dc26bd for perf build]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Change-Id: Ifcded1bb028928b2d32c3c315c7bfa8cfd0a9d58
Arnaldo Carvalho de Melo [Mon, 13 May 2019 17:23:42 +0000 (13:23 -0400)]
tools arch: Update arch/x86/lib/memcpy_64.S copy used in 'perf bench mem memcpy'
To bring in the change made in this cset:
b69656fa7ea2 ("x86/uaccess: Fix up the fixup")
Silencing this perf build warning:
Warning: Kernel ABI header at 'tools/arch/x86/lib/memcpy_64.S' differs from latest version at 'arch/x86/lib/memcpy_64.S'
diff -u tools/arch/x86/lib/memcpy_64.S arch/x86/lib/memcpy_64.S
No changes in the tooling using this, that was just to ease some objtool
return checking.
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: https://lkml.kernel.org/n/tip-j0mxgqkuibhw5qid9saaspdu@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
[sw0312.kim: cherry-pick mainline commit
a021b5400111 for perf build]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Change-Id: Icc22d689c8a1beacb4caa574c0a71bbd1b20f951
Arnaldo Carvalho de Melo [Mon, 13 May 2019 17:27:12 +0000 (13:27 -0400)]
tools arch uapi: Sync the x86 kvm.h copy
To get the changes in:
59073aaf6de0 ("kvm: x86: Add exception payload fields to kvm_vcpu_events")
This silences the following perf build warning:
Warning: Kernel ABI header at 'tools/arch/x86/include/uapi/asm/kvm.h' differs from latest version at 'arch/x86/include/uapi/asm/kvm.h'
diff -u tools/arch/x86/include/uapi/asm/kvm.h arch/x86/include/uapi/asm/kvm.h
The changes in this file are in something not used at this time in any
tools/perf/ tool.
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Jim Mattson <jmattson@google.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Paolo Bonzini <pbonzini@redhat.com>
Link: https://lkml.kernel.org/n/tip-6uh8tpraons0h22dmxgfyony@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
[sw0312.kim: cherry-pick mainline commit
f98f10f35257 for perf build]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Change-Id: If00ae735efa27c7bad8a1f2cd5893b919cfc809d
Arnaldo Carvalho de Melo [Tue, 21 May 2019 19:39:42 +0000 (16:39 -0300)]
tools arch x86: Sync asm/cpufeatures.h with the with the kernel
To pick up the changes in:
ed5194c2732c ("x86/speculation/mds: Add basic bug infrastructure for MDS")
e261f209c366 ("x86/speculation/mds: Add BUG_MSBDS_ONLY")
That don't affect anything in tools/.
This silences this perf build warning:
Warning: Kernel ABI header at 'tools/arch/x86/include/asm/cpufeatures.h' differs from latest version at 'arch/x86/include/asm/cpufeatures.h'
diff -u tools/arch/x86/include/asm/cpufeatures.h arch/x86/include/asm/cpufeatures.h
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Andi Kleen <ak@linux.intel.com>
Cc: Brendan Gregg <brendan.d.gregg@gmail.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Luis Cláudio Gonçalves <lclaudio@redhat.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Link: https://lkml.kernel.org/n/tip-jp1afecx3ql1jkuirpgkqfad@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
[sw0312.kim: cherry-pick mainline commit
b979540a7522 for perf build]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Change-Id: I879810548387101141f808c1c972f691c906c3e1
Arnaldo Carvalho de Melo [Mon, 25 Mar 2019 17:25:33 +0000 (14:25 -0300)]
tools arch x86: Sync asm/cpufeatures.h with the kernel sources
To get the changes from:
52f64909409c ("x86: Add TSX Force Abort CPUID/MSR")
That don't cause any changes in the generated perf binaries.
And silence this perf build warning:
Warning: Kernel ABI header at 'tools/arch/x86/include/asm/cpufeatures.h' differs from latest version at 'arch/x86/include/asm/cpufeatures.h'
diff -u tools/arch/x86/include/asm/cpufeatures.h arch/x86/include/asm/cpufeatures.h
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Link: https://lkml.kernel.org/n/tip-zv8kw8vnb1zppflncpwfsv2w@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
[sw0312.kim: cherry-pick mainline commit
949af89af02c for perf build]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Change-Id: I2c20b8306175133ee6445c69fb68575f2c4eba9e
Arnaldo Carvalho de Melo [Thu, 6 Dec 2018 14:20:21 +0000 (11:20 -0300)]
perf help: Remove needless use of strncpy()
commit
b6313899f4ed2e76b8375cf8069556f5b94fbff0 upstream.
Since we make sure the destination buffer has at least strlen(orig) + 1,
no need to do a strncpy(dest, orig, strlen(orig)), just use strcpy(dest,
orig).
This silences this gcc 8.2 warning on Alpine Linux:
In function 'add_man_viewer',
inlined from 'perf_help_config' at builtin-help.c:284:3:
builtin-help.c:192:2: error: 'strncpy' output truncated before terminating nul copying as many bytes from a string as its length [-Werror=stringop-truncation]
strncpy((*p)->name, name, len);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
builtin-help.c: In function 'perf_help_config':
builtin-help.c:187:15: note: length computed here
size_t len = strlen(name);
^~~~~~~~~~~~
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Fixes:
078006012401 ("perf_counter tools: add in basic glue from Git")
Link: https://lkml.kernel.org/n/tip-2f69l7drca427ob4km8i7kvo@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
[sw0312.kim: cherry-pick stable linux-4.19.y commit
0bf5d53b53c8 for gcc 9 build]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Change-Id: Id98e9ca8049d25d658b4f012fdede1b8745d875f
Arnaldo Carvalho de Melo [Thu, 6 Dec 2018 14:09:46 +0000 (11:09 -0300)]
perf header: Fix unchecked usage of strncpy()
commit
5192bde7d98c99f2cd80225649e3c2e7493722f7 upstream.
The strncpy() function may leave the destination string buffer
unterminated, better use strlcpy() that we have a __weak fallback
implementation for systems without it.
This fixes this warning on an Alpine Linux Edge system with gcc 8.2:
util/header.c: In function 'perf_event__synthesize_event_update_name':
util/header.c:3625:2: error: 'strncpy' output truncated before terminating nul copying as many bytes from a string as its length [-Werror=stringop-truncation]
strncpy(ev->data, evsel->name, len);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
util/header.c:3618:15: note: length computed here
size_t len = strlen(evsel->name);
^~~~~~~~~~~~~~~~~~~
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Fixes:
a6e5281780d1 ("perf tools: Add event_update event unit type")
Link: https://lkml.kernel.org/n/tip-wycz66iy8dl2z3yifgqf894p@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
[sw0312.kim: cherry-pick stable linux-4.19.y commit
6461a4543b34 for gcc 9 build]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Change-Id: I2d116858af62b094276699c790b7ba090fe28513
Seung-Woo Kim [Fri, 20 Dec 2019 06:30:13 +0000 (15:30 +0900)]
ARM: configs: tizen_bcm2709_defconfig: Enable tethering config options
In Tizen 6.0, network framework supports tethering from ethernet
to wifi. Enable required config options for tethering.
Ref: section 6-3 of https://git.tizen.org/cgit/platform/kernel/tizen-kernel-configs/tree/tizen/tizen_defconfig?h=tizen
Change-Id: I162d6eb89ce8d25d85659c7a2e632dbfe0909dc6
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Fri, 20 Dec 2019 06:35:37 +0000 (15:35 +0900)]
ARM64: tizen_bcmrpi3_defconfig: Enable tethering config options
In Tizen 6.0, network framework supports tethering from ethernet
to wifi. Enable required config options for tethering.
Ref: section 6-3 of https://git.tizen.org/cgit/platform/kernel/tizen-kernel-configs/tree/tizen/tizen_defconfig?h=tizen
Change-Id: I5df076b13a3c02257f34e368dd99aaca2b3370b0
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Junghoon Kim [Wed, 18 Dec 2019 01:53:42 +0000 (10:53 +0900)]
scripts: mkbootimg_rpi3.sh: Create boot tarball for the lthor flashing
This patch is to create boot tarball for the lthor flashing. With this,
we can easily test the rpi3 kernel in the local environment.
Change-Id: Ib7bca6f7fa2c5a51be097042eda80c2d9297d4ac
Signed-off-by: Junghoon Kim <jhoon20.kim@samsung.com>
Junghoon Kim [Wed, 18 Dec 2019 01:43:55 +0000 (10:43 +0900)]
ARM64: tizen_bcmrpi3_defconfig: Enable btrfs filesystem
Enable btrfs filesystem to use it as the rootfs mount for the
RPI4 64-bit architecture.
Change-Id: Ieb13f6970dbfd8c947c501cfad1c7eb9ee4d2799
Signed-off-by: Junghoon Kim <jhoon20.kim@samsung.com>
Junghoon Kim [Wed, 18 Dec 2019 01:26:43 +0000 (10:26 +0900)]
ARM: tizen_bcm2709_defconfig: Enable btrfs filesystem
Enable btrfs filesystem to use it as the rootfs mount for the
RPI3 32-bit architecture.
Change-Id: I697e2fc9cbf4c8f69a94afed0e2244c3b8accad7
Signed-off-by: Junghoon Kim <jhoon20.kim@samsung.com>
Seung-Woo Kim [Thu, 5 Dec 2019 07:52:29 +0000 (16:52 +0900)]
drm/vc4: fix wrong filp usage in gem_info debugfs node
After the mainline commit
65101d8c9108 ("drm/vc4: Expose
performance counters to userspace") applied in v4.17, vc4 drm
has its own filp. So gem_info filp usage is not proper. Fix the
wrong filp usage in gem_info debugfs node.
Change-Id: I526a888f345378d66f96e9d6cd3d19527e56ddaa
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Wed, 20 Nov 2019 08:12:09 +0000 (17:12 +0900)]
ARM: configs: tizen_bcm2709_defconfig: Enable HID_MULTITOUCH
To support usb multi-touch device, enable CONFIG_HID_MULTITOUCH.
Change-Id: I2423291698367912d379787e94dc75659f414a31
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Wed, 20 Nov 2019 08:10:48 +0000 (17:10 +0900)]
ARM64: configs: tizen_bcmrpi3_defconfig: Enable HID_MULTITOUCH
To support usb multi-touch device, enable CONFIG_HID_MULTITOUCH.
Change-Id: I36f625f08b980e7a5ed8cea9e061ba0d4d56d39b
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Fri, 1 Nov 2019 01:17:15 +0000 (10:17 +0900)]
packaging: replace -fPIC to -fPIE for perf executable
Build issue for perf is from linking perf executable, so pie flag
is suitabler than pic flag. Replace -fPIC to -fPIE for perf
executable and add the flag to missed perf install part.
Change-Id: I0911dc2b3ffc54724927846f5e081da9d7335c39
Suggested-by: Dongkyun Son <dongkyun.s@samsung.com>
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Thu, 31 Oct 2019 03:42:36 +0000 (12:42 +0900)]
packaging: Add -fPIC flag to perf build cflags
Current Tizen build environment requires -fPIC with relocation
and without the flag, there is build error for perf like below:
armv7l
armv7l-tizen-linux-gnueabi/bin/ld: perf-in.o: relocation R_ARM_MOVW_ABS_NC against `__stack_chk_guard' can not be used when making a shared object; recompile with -fPIC
aarch64
aarch64-tizen-linux-gnu/bin/ld: perf-in.o: relocation R_AARCH64_ADR_PREL_PG_HI21 against external symbol `__stack_chk_guard@@GLIBC_2.17' can not be used when making a shared object; recompile with -fPIC
aarch64-tizen-linux-gnu/bin/ld: perf-in.o(.text+0x4): unresolvable R_AARCH64_ADR_PREL_PG_HI21 relocation against symbol `__stack_chk_guard@@GLIBC_2.17'
Add -fPIC flag to perf build.
Change-Id: Icca04801698c88180dfde493a3ef92e5c01612b5
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Fri, 11 Oct 2019 04:47:47 +0000 (13:47 +0900)]
ARM: configs: tizen_bcm2709_defconfig: Enable EXTCON for hdmi
Enable CONFIG_EXTCON for hdmi connection uevent.
Change-Id: I62cc93151019209661600af2a63f087d25112490
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Fri, 11 Oct 2019 04:46:34 +0000 (13:46 +0900)]
ARM64: configs: tizen_bcmrpi3_defconfig: Enable EXTCON for hdmi
Enable CONFIG_EXTCON for hdmi connection uevent.
Change-Id: I912b8dddf6e2fbc13075ad6f83fbd06ea55f6d90
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Fri, 11 Oct 2019 04:43:33 +0000 (13:43 +0900)]
drm/vc4: add extcon hdmi connection uevent
Add extcon hdmi connection and disconnection ueven when extcon
module is enabled.
The vc4 hdmi detection is done by polling way, so extcon uevent
for connection is a bit slow after changing real hdmi cable state.
Change-Id: I962f7a39b7a3344f9793e436ef28c36b123571a8
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Mon, 23 Sep 2019 09:00:11 +0000 (18:00 +0900)]
scripts: mkbootimg_rpi3.sh: Fix to install modules on non sudo status
On sudo status, env variable is possible not to be preserved and
it causes failure on modules_install. So fix to install modules on
non sudo status and then move the directories and files to image
area.
Change-Id: Ie1e0ff695caf79b1ce3d25be8a70151a30fbfee0
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Jaehoon Chung [Tue, 17 Sep 2019 05:10:17 +0000 (14:10 +0900)]
build: script: combine rpi3 32bit and 64bit scripts
Combine rpi3 32bit and 64bit scripts.
e.g) build-rpi3.sh arm / arm64
Change-Id: I224b7944362245685e4557f2fe41837c3a685ad8
Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
Seung-Woo Kim [Thu, 5 Sep 2019 00:14:46 +0000 (09:14 +0900)]
packaging: add perf package for perf tool and traceevent plugins
Add perf package for perf tool and its traceevent plugins.
Note: they are built from below directories.
- perf: tools/perf
- traceevent plugins: tools/lib/traceevent
Change-Id: I418c52ec7dffb6b98e72e402af5bf67c3d837ba7
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Wed, 28 Aug 2019 08:13:22 +0000 (17:13 +0900)]
ARM: configs: tizen_bcm2709_defconfig: Enable NETFILTER_XT_MATCH_LIMIT
From Tizen network security, NETFILTER_XT_MATCH_LIMIT is used for
ipv6. So enable NETFILTER_XT_MATCH_LIMIT config option.
Change-Id: Ife75ee0a766c64fb38a0e261f41a45678ab49bd4
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Wed, 28 Aug 2019 08:11:56 +0000 (17:11 +0900)]
ARM64: configs: tizen_bcmrpi3_defconfig: Enable NETFILTER_XT_MATCH_LIMIT
From Tizen network security, NETFILTER_XT_MATCH_LIMIT is used for
ipv6. So enable NETFILTER_XT_MATCH_LIMIT config option.
Change-Id: Ieeba2c67481e299fb3d91ee4378f8b2a2baffc7b
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Wed, 31 Jul 2019 08:01:06 +0000 (17:01 +0900)]
ARM: configs: tizen_bcm2709_defconfig: Enable NETFILTER_XT_MATCH_OWNER config
Enable the NETFILTER_XT_MATCH_OWNER config option to use xt_owner
supplementary groups.
Change-Id: I10a8277e2c42cae8cd02eb892e2dac5124681a71
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Wed, 31 Jul 2019 08:00:32 +0000 (17:00 +0900)]
ARM64: configs: tizen_bcmrpi3_defconfig: Enable NETFILTER_XT_MATCH_OWNER config
Enable the NETFILTER_XT_MATCH_OWNER config option to use xt_owner
supplementary groups.
Change-Id: I1baf6d78dc7c28d7235bb1cce9b6132b2fba7148
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Thu, 25 Jul 2019 07:34:59 +0000 (16:34 +0900)]
ARM: dts: bcm2710-rpi-3-b-plus: remove duplicated uart0_ctsrts_gpio30 node
The commit
ad3b011329c8 ("ARM: dts: bcm2710-rpi-3-b-plus: Add cts
pin setting for bluetooth uart") introduced duplicated dt node,
uart0_ctsrts_gpio30, because it is already defined in bcm283x.dtsi.
Remove the duplicated dt node.
Change-Id: Ic9a39b88662198f30b585f48f2f0e896b62ab8f3
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
DoHyun Pyun [Thu, 25 Jul 2019 03:45:21 +0000 (12:45 +0900)]
Revert "Bluetooth : Set the optimized operation speed for BCM Uart"
This reverts commit
5cc55680fc9fe5bfd7590905c56e55dfa4aefbd5.
The proper operation speed of the RPI3 Uart is different for
each HW revision. So we will set the value in the user space's
firmware downloading tool after checking the HW version.
Change-Id: I95d80f3598015a27fbdc1375b3d6c089be67b8d0
Signed-off-by: DoHyun Pyun <dh79.pyun@samsung.com>
Seung-Woo Kim [Tue, 23 Jul 2019 09:31:05 +0000 (18:31 +0900)]
ARM: dts: bcm2710-rpi-3-b-plus: Add cts pin setting for bluetooth uart
There is missing cts pin for uart0 used by bluetooth. Add the cts
pin setting as like bcm2837-rpi-3-b-plus.
Change-Id: Iefdf80ec0d523b85f7a6e579e1544a67b9139212
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Phil Elwell [Thu, 11 Jul 2019 12:13:39 +0000 (13:13 +0100)]
tty: amba-pl011: Make TX optimisation conditional
pl011_tx_chars takes a "from_irq" parameter to reduce the number of
register accesses. When from_irq is true the function assumes that the
FIFO is half empty and writes up to half a FIFO's worth of bytes
without polling the FIFO status register, the reasoning being that
the function is being called as a result of the TX interrupt being
raised. This logic would work were it not for the fact that
pl011_rx_chars, called from pl011_int before pl011_tx_chars, releases
the spinlock before calling tty_flip_buffer_push.
A user thread writing to the UART claims the spinlock and ultimately
calls pl011_tx_chars with from_irq set to false. This reverts to the
older logic that polls the FIFO status register before sending every
byte. If this happen on an SMP system during the section of the IRQ
handler where the spinlock has been released, then by the time the TX
interrupt handler is called, the FIFO may already be full, and any
further writes are likely to be lost.
The fix involves adding a per-port flag that is true iff running from
within the interrupt handler and the spinlock has not yet been released.
This flag is then used as the value for the from_irq parameter of
pl011_tx_chars, causing polling to be used in the unsafe case.
Fixes:
1e84d22322ce ("serial/amba-pl011: Refactor and simplify TX FIFO handling")
Signed-off-by: Phil Elwell <phil@raspberrypi.org>
[sw0312.kim: cherry-pick from rpi-4.19.y to reduce bt reassembly issue]
Reference: https://github.com/raspberrypi/firmware/issues/1150
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Change-Id: Ia56b9fffb8805ca02d04ed9c9b810988e1b56642
Seung-Woo Kim [Tue, 23 Jul 2019 01:28:13 +0000 (10:28 +0900)]
packaging: Add _wrong_version_format_terminate_build macro
Newer version of rpmbuild rejects double dash, "-", in version.
To support the style, add _worng_version_format_terminate_build
as 0.
Change-Id: Ieed243fb4ad7059b83d5328f0c38b15e4c74dc0e
Reference: https://github.com/rpm-software-management/rpm/commit/
5e94633660d0e2b97
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Mon, 22 Jul 2019 06:00:12 +0000 (15:00 +0900)]
packaging: remove macro in package Name
Some build system cannot recognize macro in package Name. Remove
the macro by replacing with same string.
Change-Id: I34c853be82476db3b32d49aadc77809a2f493436
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
DoHyun Pyun [Wed, 17 Jul 2019 07:08:46 +0000 (16:08 +0900)]
Bluetooth : Set the optimized operation speed for BCM Uart
When ACL data packet transfers via Uart on the RPI3 board,
the packet loss or overflow issue is occured. After adjusting
the operation speed value, we can reduce these problems.
Change-Id: Id072102e173e0338c4ae3cb7a1a541fbf7f8066e
Signed-off-by: DoHyun Pyun <dh79.pyun@samsung.com>
Seung-Woo Kim [Wed, 17 Jul 2019 01:56:16 +0000 (10:56 +0900)]
Bluetooth: fix wrong indent in __hci_req_update_{scan/adv}_rsp_data()
The commit
ac160e08af69 ("Bluetooth: Add Advertising Packet
Configuration") introduces wrong indent which causes build warning for
gcc-7. Fix the wrong indent.
Change-Id: Ia0bde8a8f9660ccf8fa312e3c3ec6c8cb76863f1
Fixes:
ac160e08af69 ("Bluetooth: Add Advertising Packet Configuration")
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Fri, 12 Jul 2019 05:13:37 +0000 (14:13 +0900)]
ARM64: configs: tizen_bcmrpi3_defconfig: Enable BCM Uart protocol
RPI3 target uses the BCM BT chip of the Uart type. To avoid the
reassembly failed problem, we should enable BCM Uart protocol
and need to use it. It is enabled with CONFIG_SERIAL_DEV_BUS.
Change-Id: I960ddb6f6b3cb64261ebcdc750771943697948ae
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
DoHyun Pyun [Fri, 12 Jul 2019 04:45:10 +0000 (13:45 +0900)]
ARM: configs: tizen_bcm2709_defconfig: Enable BCM Uart protocol
RPI3 target uses the BCM BT chip of the Uart type. To avoid the
reassembly failed problem, we should enable BCM Uart protocol
and need to use it. It is enabled with CONFIG_SERIAL_DEV_BUS.
Change-Id: I3cf97b032e1ce92898f2329fae3691d4d5870726
Signed-off-by: DoHyun Pyun <dh79.pyun@samsung.com>
[sw0312.kim: adjust defconfig with savedefconfig and update commit-msg]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Hoegeun Kwon [Thu, 4 Jul 2019 08:42:52 +0000 (17:42 +0900)]
ARM: dts: bcm27xx: Fix to of_graph from bridge node for touchscreen
Beginning with kernel v4.15, the i2c management of the touchscreen
panel driver has been changed to use of_graph from brdge node. So
change to of_graph and remove the unnecessary nodes.
Change-Id: I6ef786ed472ef2b350eb8683568d0ecb407182c0
Signed-off-by: Hoegeun Kwon <hoegeun.kwon@samsung.com>
Hoegeun Kwon [Thu, 4 Jul 2019 08:40:58 +0000 (17:40 +0900)]
drm/vc4: Fix change to find_panel in the dsi_attach func
There is a problem that crtc does not bind while continuously
requesting EPROBE_DEFER, if dsi_bind does not successfully bind.
We need to change the part of find_panel in bind to dsi_attach
function.
Change-Id: Ifce518f047f496079eb8fbe112dabbd9bc7488bb
Signed-off-by: Hoegeun Kwon <hoegeun.kwon@samsung.com>
Pablo Neira Ayuso [Fri, 7 Jun 2019 14:37:30 +0000 (16:37 +0200)]
netfilter: xt_owner: bail out with EINVAL in case of unsupported flags
Reject flags that are not supported with EINVAL.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
[sw0312.kim: backport from mainline to apply supplementary groups on netfilter]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Change-Id: Id867ca48290a8e6627ad7d1b1f159669fc5c44a1
Lukasz Pawelczyk [Fri, 10 May 2019 11:46:22 +0000 (13:46 +0200)]
netfilter: xt_owner: Add supplementary groups option
The XT_OWNER_SUPPL_GROUPS flag causes GIDs specified with XT_OWNER_GID
to be also checked in the supplementary groups of a process.
f_cred->group_info cannot be modified during its lifetime and f_cred
holds a reference to it so it's safe to use.
Signed-off-by: Lukasz Pawelczyk <l.pawelczyk@samsung.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
[sw0312.kim: backport from mainline to apply supplementary groups on netfilter]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Change-Id: I7a21fc112cde77ae708b84d4b48c8aee339a7642
Hoegeun Kwon [Wed, 3 Jul 2019 05:16:46 +0000 (14:16 +0900)]
ARM: configs: tizen_bcm2709_defconfig: Remove unused modules
Remove unused modules from the backlight.
Change-Id: I1fd5267690efd4a7bd5137b64dfadba5111dc2dd
Signed-off-by: Hoegeun Kwon <hoegeun.kwon@samsung.com>
DoHyun Pyun [Thu, 4 Jul 2019 00:18:21 +0000 (09:18 +0900)]
Bluetooth: Fix the potential crash issue
There is a logic error in the event function. We should
check the callback function's parameter before calling.
Change-Id: I06a4a8c50317e5ec4ae8fe35e4b788105e090196
Fixes:
bde01c80dd51 ("Bluetooth: Set le data length command and event")
Signed-off-by: DoHyun Pyun <dh79.pyun@samsung.com>
Hoegeun Kwon [Wed, 3 Jul 2019 05:18:50 +0000 (14:18 +0900)]
tools: Add build script for ARM kernel of rpi3
Add build script for ARM kernel of rpi3.
Change-Id: I35a7dd2148350f775d3d96a478dac66190079d68
Signed-off-by: Hoegeun Kwon <hoegeun.kwon@samsung.com>
Hoegeun Kwon [Wed, 3 Jul 2019 10:22:11 +0000 (19:22 +0900)]
Revert "ARM: dts: bcm27xx: Fix to of_graph from bridge node for panel"
This reverts commit
b2f6ad21a0bab8e59926666f717a4f6c53066a2d.
There is a problem with the hdmi and revert the patch.
Change-Id: Ia69d10c067ff69d192162b0598f43028c4a05f9b
Signed-off-by: Hoegeun Kwon <hoegeun.kwon@samsung.com>
Hoegeun Kwon [Tue, 2 Jul 2019 02:08:59 +0000 (11:08 +0900)]
ARM: dts: bcm27xx: Fix to of_graph from bridge node for panel
Beginning with kernel v4.15, the i2c management of the touchscreen
panel driver has been changed to use of_graph from brdge node. So
change to of_graph and remove the unnecessary nodes.
Change-Id: Ibf131aebd964360874ebe2f3792f0912f6e8988d
Signed-off-by: Hoegeun Kwon <hoegeun.kwon@samsung.com>
Sudha Bheemanna [Fri, 16 Sep 2016 10:07:22 +0000 (15:37 +0530)]
Bluetooth: Set le data length command and event
Sets the data length for the le data packet with in the
advised limits. MGMT command and event are added to handle
the setting of data length.
Change-Id: Ia5c2167743cc9a29190e5631973e9d52d41caa1d
Signed-off-by: Sudha Bheemanna <b.sudha@samsung.com>
Signed-off-by: Amit Purwar <amit.purwar@samsung.com>