Thomas Abraham [Fri, 3 Apr 2015 16:43:46 +0000 (18:43 +0200)]
clk: samsung: exynos4: add cpu clock configuration data and instantiate cpu clock
With the addition of the new Samsung specific cpu-clock type, the
arm clock can be represented as a cpu-clock type. Add the CPU clock
configuration data and instantiate the CPU clock type for Exynos4210.
Changes by Bartlomiej:
- fixed issue with wrong dividers being setup by Common Clock Framework
(by an addition of CLK_RECALC_NEW_RATES clock flag to mout_apll clock,
without this change cpufreq-dt driver showed ~10 mA larger energy
consumption when compared to cpufreq-exynos one when "performance"
cpufreq governor was used on Exynos4210 SoC based Origen board), this
was probably meant to be workarounded by use of CLK_GET_RATE_NOCACHE
and CLK_DIVIDER_READ_ONLY clock flags in the original patchset (in
"[PATCH v12 6/6] clk: samsung: remove unused clock aliases and update
clock flags") but using these flags is not sufficient to fix the issue
observed
- removed Exynos5250 and Exynos5420 support for now
Cc: Tomasz Figa <tomasz.figa@gmail.com>
Cc: Mike Turquette <mturquette@linaro.org>
Cc: Javier Martinez Canillas <javier.martinez@collabora.co.uk>
Signed-off-by: Thomas Abraham <thomas.ab@samsung.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
Thomas Abraham [Fri, 3 Apr 2015 16:43:45 +0000 (18:43 +0200)]
clk: samsung: add infrastructure to register cpu clocks
The CPU clock provider supplies the clock to the CPU clock domain. The
composition and organization of the CPU clock provider could vary among
Exynos SoCs. A CPU clock provider can be composed of clock mux, dividers
and gates. This patch defines a new clock type for CPU clock provider and
adds infrastructure to register the CPU clock providers for Samsung
platforms.
Changes by Bartlomiej:
- fixed issue with setting lower dividers before the parent clock speed
was lowered (the issue resulted in lockup on Exynos4210 SoC based
Origen board when "ondemand" cpufreq governor was stress tested)
- fixed missing spin_unlock on error in exynos_cpuclk_post_rate_change()
problem by moving cfg_data search outside of the spin locked area
- removed leftover kfree() in exynos_register_cpu_clock() that could
result in dereferencing the NULL pointer on error
- moved spin_lock earlier in exynos_cpuclk_pre_rate_change() to cover
reading of E4210_SRC_CPU and E4210_DIV_CPU1 registers
- added missing "last chance" checks to wait_until_divider_stable() and
wait_until_mux_stable() (needed in case that IRQ handling took long
time to proceed and resulted in function printing incorrect error
message about timeout)
- moved E4210_CPU_DIV[0,1]() macros just before their only users,
this resulted in moving them from patch #2 to patch #3/6 ("clk:
samsung: exynos4: add cpu clock configuration data and instantiate
cpu clock")
- removed E5250_CPU_DIV[0,1](), E5420_EGL_DIV0() and E5420_KFC_DIV()
macros for now
- added my Copyrights to drivers/clk/samsung/clk-cpu.c
Cc: Tomasz Figa <tomasz.figa@gmail.com>
Cc: Mike Turquette <mturquette@linaro.org>
Cc: Javier Martinez Canillas <javier.martinez@collabora.co.uk>
Signed-off-by: Thomas Abraham <thomas.ab@samsung.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
Bartlomiej Zolnierkiewicz [Fri, 3 Apr 2015 16:43:44 +0000 (18:43 +0200)]
clk: add CLK_RECALC_NEW_RATES clock flag for Exynos cpu clock support
This flag is needed to fix the issue with wrong dividers being setup
by Common Clock Framework when using the new Exynos cpu clock support.
The issue happens because clk_core_set_rate_nolock() calls
clk_calc_new_rates(clk, rate) before both pre/post clock notifiers have
a chance to run. In case of Exynos cpu clock support pre/post clock
notifiers are registered for mout_apll clock which is a parent of armclk
cpu clock and dividers are modified in both pre and post clock notifier.
This results in wrong dividers values being later programmed by
clk_change_rate(top). To workaround the problem CLK_RECALC_NEW_RATES
flag is added and it is set for mout_apll clock later so the correct
divider values are re-calculated after both pre and post clock notifiers
had run.
For example when using "performance" governor on Exynos4210 Origen board
the cpufreq-dt driver requests to change the frequency from 1000MHz to
1200MHz and after the change state of the relevant clocks is following:
Without use of CLK_GET_RATE_NOCACHE flag:
fout_apll rate:
1200000000
fout_apll_div_2 rate:
600000000
mout_clkout_cpu rate:
600000000
div_clkout_cpu rate:
600000000
clkout_cpu rate:
600000000
mout_apll rate:
1200000000
armclk rate:
1200000000
mout_hpm rate:
1200000000
div_copy rate:
300000000
div_hpm rate:
300000000
mout_core rate:
1200000000
div_core rate:
1200000000
div_core2 rate:
1200000000
arm_clk_div_2 rate:
600000000
div_corem0 rate:
300000000
div_corem1 rate:
150000000
div_periph rate:
300000000
div_atb rate:
300000000
div_pclk_dbg rate:
150000000
sclk_apll rate:
1200000000
sclk_apll_div_2 rate:
600000000
With use of CLK_GET_RATE_NOCACHE flag:
fout_apll rate:
1200000000
fout_apll_div_2 rate:
600000000
mout_clkout_cpu rate:
600000000
div_clkout_cpu rate:
600000000
clkout_cpu rate:
600000000
mout_apll rate:
1200000000
armclk rate:
1200000000
mout_hpm rate:
1200000000
div_copy rate:
200000000
div_hpm rate:
200000000
mout_core rate:
1200000000
div_core rate:
1200000000
div_core2 rate:
1200000000
arm_clk_div_2 rate:
600000000
div_corem0 rate:
300000000
div_corem1 rate:
150000000
div_periph rate:
300000000
div_atb rate:
240000000
div_pclk_dbg rate:
120000000
sclk_apll rate:
150000000
sclk_apll_div_2 rate:
75000000
Without this change cpufreq-dt driver showed ~10 mA larger energy
consumption when compared to cpufreq-exynos one when "performance"
cpufreq governor was used on Exynos4210 SoC based Origen board.
This issue was probably meant to be workarounded by use of
CLK_GET_RATE_NOCACHE and CLK_DIVIDER_READ_ONLY clock flags in
the original Exynos cpu clock patchset (in "[PATCH v12 6/6] clk:
samsung: remove unused clock aliases and update clock flags" patch)
but usage of these flags is not sufficient to fix the issue observed.
Cc: Thomas Abraham <thomas.ab@samsung.com>
Cc: Tomasz Figa <tomasz.figa@gmail.com>
Cc: Mike Turquette <mturquette@linaro.org>
Cc: Javier Martinez Canillas <javier.martinez@collabora.co.uk>
Signed-off-by: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
Bartlomiej Zolnierkiewicz [Fri, 27 Mar 2015 16:32:53 +0000 (17:32 +0100)]
cpufreq: exynos: remove dead ->need_apll_change method
Commit
26ab1c62b6e1 ("cpufreq: exynos5250: Set APLL rate
using CCF API") removed the last user of ->need_apll_change
method. Remove it and then cleanup exynos_cpufreq_scale()
accordingly.
This patch was tested on Exynos4412 SoC based Trats2 board.
There should be no functional changes caused by this patch.
Cc: Sachin Kamat <sachin.kamat@linaro.org>
Cc: Lukasz Majewski <l.majewski@samsung.com>
Cc: Kukjin Kim <kgene@kernel.org>
Signed-off-by: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
Marek Szyprowski [Thu, 16 Apr 2015 09:52:33 +0000 (11:52 +0200)]
media: s5p-jpeg: add RGB565 format to Exynos4 buffer size workaround
JPEG HW can access buffer beyond the image data for images, which width
or height is not properly aligned. This patch adds RGB565 format to
workaround code to solve IOMMU page fault issue. The exact needed buffer
enlargement workaround need to be determined experimentally.
Reported-by: Inha Song <ideal.song@samsung.com>
Suggested-by: Andrzej Pietrasiewicz <andrzej.p@samsung.com>
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Inha Song [Thu, 16 Apr 2015 07:59:40 +0000 (16:59 +0900)]
packaging: change version to 4.1
This patch change version to 4.1 from 4.0.0 because of upstream tag.
Change-Id: I6ef7dfedcf1decb07ca5ab6aaec5b5f462f084fa
Signed-off-by: Inha Song <ideal.song@samsung.com>
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Inha Song [Thu, 16 Apr 2015 07:56:39 +0000 (16:56 +0900)]
packaging: use upstream tags
Change-Id: Ib6eaf6e12ecc8f065b085253dbcc0c538caff511
Signed-off-by: Inha Song <ideal.song@samsung.com>
Inha Song [Tue, 17 Mar 2015 01:58:16 +0000 (10:58 +0900)]
packaging: add spec file to generate odroid-xu3 kernel by GBS
This patch add spec file to generate odroid-xu3 kernel-headers by GBS.
Signed-off-by: Inha Song <ideal.song@samsung.com>
Seung-Woo Kim [Tue, 9 Jun 2015 04:48:17 +0000 (13:48 +0900)]
ARM: odroidxu3_defconfig: enable fuse
This patch enables fuse config to support user file system.
Change-Id: I6543ace82673ab4108ea3154524cee5fb29a4760
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Thu, 14 May 2015 05:08:18 +0000 (14:08 +0900)]
ARM: odroidxu3_defconfig: enable trace and debug configs
This patch enables trace and debug configs to support user trace
request.
Change-Id: I7a63a7cf9d7bb5510434db8ff2fcc4ae8f7938bb
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Thu, 16 Apr 2015 04:29:52 +0000 (13:29 +0900)]
ARM: odroidxu3_defconfig: enable uinput config
This patch enables uinput config to support userland input driver.
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Krzysztof Kozlowski [Wed, 11 Mar 2015 10:13:57 +0000 (11:13 +0100)]
ARM: EXYNOS: Fix failed second suspend on Exynos4
On Exynos4412 boards (Trats2, Odroid U3) after enabling L2 cache in
56b60b8bce4a ("ARM: 8265/1: dts: exynos4: Add nodes for L2 cache
controller") the second suspend to RAM failed. First suspend worked fine
but the next one hang just after powering down of secondary CPUs (system
consumed energy as it would be running but was not responsive).
The issue was caused by enabling delayed reset assertion for CPU0 just
after issuing power down of cores. This was introduced for Exynos4 in
13cfa6c4f7fa ("ARM: EXYNOS: Fix CPU idle clock down after CPU off").
The whole behavior is not well documented but after checking with vendor
code this should be done like this (on Exynos4):
1. Enable delayed reset assertion when system is running (for all CPUs).
2. Disable delayed reset assertion before suspending the system.
This can be done after powering off secondary CPUs.
3. Re-enable the delayed reset assertion when system is resumed.
Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Fixes:
13cfa6c4f7fa ("ARM: EXYNOS: Fix CPU idle clock down after CPU off")
Cc: <stable@vger.kernel.org>
Tested-by: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
Tested-by: Chanwoo Choi <cw00.choi@samsung.com>
Inha Song [Mon, 9 Mar 2015 05:21:18 +0000 (14:21 +0900)]
ARM: odroidxu3_defconfig: update configs to Linux 4.1
This patch updates odroid configs to Linux 4.1 for tizen.
Change-Id: Iaf3770b31bdb38ec72bb844e4ea62e9373de877f
Signed-off-by: Inha Song <ideal.song@samsung.com>
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Joonyoung Shim [Wed, 8 Apr 2015 07:23:52 +0000 (16:23 +0900)]
ARM: dts: exynos5420: fix clk of mali node
Need only CLK_G3D gate clock for mali and use clk_mali name to control
the clock from mali core codes.
Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
Joonyoung Shim [Wed, 8 Apr 2015 07:22:16 +0000 (16:22 +0900)]
gpu: arm: midgard: remove clk and regulator control from exynos5422
Clk and regulator of mali will be controlled mali core codes.
Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
Marek Szyprowski [Thu, 2 Apr 2015 11:18:58 +0000 (13:18 +0200)]
arm: exynos5420.dts: add FIMC_3AA async bridge clock to GSC power domain
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Seung-Woo Kim [Tue, 6 Jan 2015 08:32:34 +0000 (17:32 +0900)]
ARM: dts: add lcd-wb flag to gsc dt nodes for Odroid XU3 board
This patch adds lcd-wb binding flag to gsc dt nodes to bind with
exynos drm gsc driver.
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Mon, 23 Mar 2015 05:25:40 +0000 (14:25 +0900)]
ARM: dts: exynos5422-odroidxu3: add gpio key dt node
This patch adds gpio key dt node for power button. The dt nodes
are ported from https://github.com/hardkernel/linux.git
+refs/heads/odroidxu3-3.10.y.
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Mon, 23 Mar 2015 05:18:52 +0000 (14:18 +0900)]
ARM: dts: exynos5422-odroidxu3: add leds dt nodes
This patch adds leds dt nodes to support rgb led devices. The dt
nodes are ported from https://github.com/hardkernel/linux.git
+refs/heads/odroidxu3-3.10.y.
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Robert Baldyga [Mon, 4 Aug 2014 06:56:32 +0000 (08:56 +0200)]
ARM: dts: add odroid-usbotg extcon support for odroid platform
This patch adds odroid-usbotg extcon dt node for odroid-u3 and
odroid-x.
Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
Signed-off-by: Robert Baldyga <r.baldyga@samsung.com>
[Adjust gpio dt node name with the odroid-usbotg driver]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Robert Baldyga [Mon, 23 Feb 2015 14:27:13 +0000 (15:27 +0100)]
ARM: dts: exynos5422-odroidxu3: make usbdrd3 extcon client
Signed-off-by: Robert Baldyga <r.baldyga@samsung.com>
Robert Baldyga [Wed, 4 Mar 2015 12:46:59 +0000 (13:46 +0100)]
ARM: dts: exynos5420: add snps,dis_u3_susphy_quirk to dwc3 controllers
It's needed for proper role switching in OTG mode.
Signed-off-by: Robert Baldyga <r.baldyga@samsung.com>
Robert Baldyga [Mon, 9 Mar 2015 10:12:48 +0000 (11:12 +0100)]
ARM: dts: exynos5420: set usb3_lpm_capable in dwc3 controllers
These hardware has LPM and we want to use it.
This will be necessary for OTG role switching.
Signed-off-by: Robert Baldyga <r.baldyga@samsung.com>
Robert Baldyga [Mon, 9 Mar 2015 10:09:43 +0000 (11:09 +0100)]
ARM: dts: exynos5422-odroidxu3: add odroid-usbotg extcon support
Signed-off-by: Robert Baldyga <r.baldyga@samsung.com>
Robert Baldyga [Mon, 9 Mar 2015 10:00:47 +0000 (11:00 +0100)]
extcon: add extcon-odroid-usbotg driver
This patch adds extcon driver for Odroid U3, U3+ and X boards.
It recognizes type of USB cable connected to Odroid board basing on
two signal lines VBUS_DET and OTG_ID (the second one is present only
on Odroid U3+ board).
Following table of states presents relationship between this signals
and detected cable type:
state | VBUS_DET | OTG_ID
-------------------------------
USB | H | H
invalid | H | L
disconn. | L | H
USB-Host | L | L
This driver is based on extcon-gpio driver.
Signed-off-by: Łukasz Stelmach <l.stelmach@samsung.com>
Signed-off-by: Robert Baldyga <r.baldyga@samsung.com>
Marek Szyprowski [Mon, 9 Mar 2015 09:27:57 +0000 (10:27 +0100)]
ARM: dts: exynos5420: add iommu support to jpeg devices
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Andrzej Pietrasiewicz [Fri, 6 Mar 2015 10:32:39 +0000 (11:32 +0100)]
ARM: dts: exynos5420: add nodes for jpeg codec
Signed-off-by: Andrzej Pietrasiewicz <andrzej.p@samsung.com>
Inha Song [Fri, 13 Feb 2015 01:12:37 +0000 (10:12 +0900)]
ARM: dts: Support audio on Exynos5422-odroidxu3 using simple-audio-card
Add MAX98090 audio codec, I2S interface and the sound nodes to support
audio on Exynos5422 SoC Based Odroid-XU3 board. Now we can support audio
in Odroid-XU3 board using simple-audio-card DT binding.
Signed-off-by: Inha Song <ideal.song@samsung.com>
Marek Szyprowski [Thu, 31 Jul 2014 11:43:17 +0000 (13:43 +0200)]
ARM: dts: exynos4412-odroid*: enable MFC device
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Jaehoon Chung [Thu, 26 Feb 2015 08:16:30 +0000 (17:16 +0900)]
ARM: dts: exynos5422-odroidxu3: use cd-gpio method to detect sd-card
To detect sd-card use the cd-gpio method.
It can decrease the interrupt for detecting sd-card.
Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
Jaehoon Chung [Thu, 26 Feb 2015 07:17:48 +0000 (16:17 +0900)]
ARM: dts: exynos5422-odroidxu3: support HS400 mode for eMMC
Add "mmc_hs400_1_8v" property to use HS400 mode.
(HS400 mode is supported since eMMC5.0.)
Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
Jaehoon Chung [Thu, 26 Feb 2015 06:39:03 +0000 (15:39 +0900)]
ARM: dts: exynos5422-odroidxu3: support HS200 mode for eMMC
Add "mmc-hs200_1_8v" property to use HS200 mode.
Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
Marek Szyprowski [Wed, 18 Feb 2015 11:11:00 +0000 (12:11 +0100)]
ARM: dts: exynos4: add nodes for jpeg codec
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Joonyoung Shim [Tue, 27 Jan 2015 06:13:51 +0000 (15:13 +0900)]
ARM: dts: exynos5422-odroidxu3: add pwm-fan node
Usage:
echo [0 - 255] > /sys/devices/platform/pwm-fan/hwmon/hwmon0/pwm1
Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
Jaehoon Chung [Fri, 23 Jan 2015 09:16:54 +0000 (18:16 +0900)]
regulator: s2mps11: add shutdown function
This needs for poweroff on odroid xu3 board.
Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
Marek Szyprowski [Wed, 21 Jan 2015 07:57:44 +0000 (08:57 +0100)]
ARM: dts: exynos542x: move mfc device into own bus with limited dma-range
MFC block does not support setting address base to 0, what is the default
value when using generic iommu based dma-mapping. This patch adds
additional virtual bus (with dma ranges limited to 0x10000000..0x20000000)
only for MFC device, so it gets proper dma mapping configuration. This is
a workaround until proper configuration of default dma window gets
implemented.
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Seung-Woo Kim [Fri, 27 Mar 2015 05:10:47 +0000 (14:10 +0900)]
gpu: arm : mali400: replace CONFIG_PM_RUNTIME to CONFIG_PM
After commit
464ed18ebdb6 ("PM: Eliminate CONFIG_PM_RUNTIME") which
is applied kernel version 3.19, PM_RUNTIME is eliminated. So this
patch replaces CONFIG_PM_RUNTIME to CONFIG_PM for kernel version
larger than 3.19.
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Joonyoung Shim [Tue, 20 Jan 2015 08:46:16 +0000 (17:46 +0900)]
ARM: dts: odroidxu3: add mali node
Support mali for odroid xu3 board.
Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
Joonyoung Shim [Tue, 20 Jan 2015 08:45:06 +0000 (17:45 +0900)]
ARM: dts: exynos5420: add mali node
Support mali node for exynos542x.
Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
Joonyoung Shim [Tue, 6 Jan 2015 05:52:08 +0000 (14:52 +0900)]
ARM: odroidxu3_defconfig: add defconfig file odroid XU3
This was copied from exynos_defconfig.
Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
Joonyoung Shim [Mon, 5 Jan 2015 05:29:07 +0000 (14:29 +0900)]
ARM: dts: add bootargs for odroid XU3
Add to use bootargs of dtb.
Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
Joonyoung Shim [Fri, 26 Sep 2014 10:04:46 +0000 (19:04 +0900)]
ARM: exynos: fix UART address selection for DEBUG_LL
The exynos5 SoCs using A15+A7 can boot to A15 or A7. If it boots using
A7, it can't detect right UART physical address only the part number of
CP15. It's possible to solve as checking Cluster ID additionally.
Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
Roman Kubiak [Fri, 12 Jun 2015 10:32:57 +0000 (12:32 +0200)]
netfilter: nfnetlink_queue: add security context information
This patch adds an additional attribute when sending
packet information via netlink in netfilter_queue module.
It will send additional security context data, so that
userspace applications can verify this context against
their own security databases.
Signed-off-by: Roman Kubiak <r.kubiak@samsung.com>
Acked-by: Florian Westphal <fw@strlen.de>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
[backport from mainline for security nether service]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Drew Richardson [Fri, 1 Apr 2016 19:00:00 +0000 (12:00 -0700)]
gator: Version 5.24
Signed-off-by: Drew Richardson <drew.richardson@arm.com>
[Ported from https://github.com/ARM-software/gator.git to kernel tree, out of tree files are removed]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Drew Richardson [Thu, 25 Feb 2016 22:28:20 +0000 (14:28 -0800)]
gator: The walk_stackframe function has a new argument for arm64 only starting with Linux 4.5
Signed-off-by: Drew Richardson <drew.richardson@arm.com>
[Ported from https://github.com/ARM-software/gator.git to kernel tree]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Drew Richardson [Fri, 29 Jan 2016 16:58:43 +0000 (08:58 -0800)]
gator: Fix minor Linux 4.5 issues
Signed-off-by: Drew Richardson <drew.richardson@arm.com>
[Ported from https://github.com/ARM-software/gator.git to kernel tree]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Drew Richardson [Wed, 16 Dec 2015 20:00:00 +0000 (12:00 -0800)]
gator: Version 5.23.1
Signed-off-by: Drew Richardson <drew.richardson@arm.com>
[Ported from https://github.com/ARM-software/gator.git to kernel tree, out of tree files are removed]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Mon, 25 Apr 2016 10:05:30 +0000 (19:05 +0900)]
gator: fix in-tree build for mali midgard
Because Makefile does not recognize quote string as path, so the
quotes should be removed from path string. This patch fix in-tree
build for mali midgard by removing quotes from the path in config.
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Drew Richardson [Wed, 18 Nov 2015 20:00:00 +0000 (12:00 -0800)]
gator: Version 5.23
Signed-off-by: Drew Richardson <drew.richardson@arm.com>
[Ported from https://github.com/ARM-software/gator.git to kernel tree, out of tree files are removed]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Drew Richardson [Wed, 22 Jul 2015 19:00:00 +0000 (12:00 -0700)]
gator: Version 5.22
Signed-off-by: Drew Richardson <drew.richardson@arm.com>
[Ported from https://github.com/ARM-software/gator.git to kernel tree, out of tree files are removed]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Drew Richardson [Tue, 28 Apr 2015 19:00:00 +0000 (12:00 -0700)]
gator: Version 5.21.1
Signed-off-by: Drew Richardson <drew.richardson@arm.com>
[Ported from https://github.com/ARM-software/gator.git to kernel tree, out of tree files are removed]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Drew Richardson [Sat, 28 Mar 2015 19:00:00 +0000 (12:00 -0700)]
gator: Version 5.21
Signed-off-by: Drew Richardson <drew.richardson@arm.com>
[Ported from https://github.com/ARM-software/gator.git to kernel tree, out of tree files are removed]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Drew Richardson [Thu, 20 Feb 2014 20:00:00 +0000 (12:00 -0800)]
gator: Version 5.20.2
Signed-off-by: Drew Richardson <drew.richardson@arm.com>
[Ported from https://github.com/ARM-software/gator.git to kernel tree]
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Linus Walleij [Tue, 11 Aug 2015 02:18:19 +0000 (05:18 +0300)]
ARM64: kasan: print memory assignment
This prints out the virtual memory assigned to KASan in the
boot crawl along with other memory assignments, if and only
if KASan is activated.
Example dmesg from the Juno Development board:
Memory: 1691156K/2080768K available (5465K kernel code, 444K rwdata,
2160K rodata, 340K init, 217K bss, 373228K reserved, 16384K cma-reserved)
Virtual kernel memory layout:
kasan : 0xffffff8000000000 - 0xffffff9000000000 ( 64 GB)
vmalloc : 0xffffff9000000000 - 0xffffffbdbfff0000 ( 182 GB)
vmemmap : 0xffffffbdc0000000 - 0xffffffbfc0000000 ( 8 GB maximum)
0xffffffbdc2000000 - 0xffffffbdc3fc0000 ( 31 MB actual)
fixed : 0xffffffbffabfd000 - 0xffffffbffac00000 ( 12 KB)
PCI I/O : 0xffffffbffae00000 - 0xffffffbffbe00000 ( 16 MB)
modules : 0xffffffbffc000000 - 0xffffffc000000000 ( 64 MB)
memory : 0xffffffc000000000 - 0xffffffc07f000000 ( 2032 MB)
.init : 0xffffffc0007f5000 - 0xffffffc00084a000 ( 340 KB)
.text : 0xffffffc000080000 - 0xffffffc0007f45b4 ( 7634 KB)
.data : 0xffffffc000850000 - 0xffffffc0008bf200 ( 445 KB)
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Andrey Ryabinin <ryabinin.a.a@gmail.com>
Acked-by: Catalin Marinas <catalin.marinas@arm.com>
Andrey Ryabinin [Tue, 11 Aug 2015 02:18:18 +0000 (05:18 +0300)]
arm64: add KASAN support
This patch adds arch specific code for kernel address sanitizer
(see Documentation/kasan.txt).
1/8 of kernel addresses reserved for shadow memory. There was no
big enough hole for this, so virtual addresses for shadow were
stolen from vmalloc area.
At early boot stage the whole shadow region populated with just
one physical page (kasan_zero_page). Later, this page reused
as readonly zero shadow for some memory that KASan currently
don't track (vmalloc).
After mapping the physical memory, pages for shadow memory are
allocated and mapped.
Functions like memset/memmove/memcpy do a lot of memory accesses.
If bad pointer passed to one of these function it is important
to catch this. Compiler's instrumentation cannot do this since
these functions are written in assembly.
KASan replaces memory functions with manually instrumented variants.
Original functions declared as weak symbols so strong definitions
in mm/kasan/kasan.c could replace them. Original functions have aliases
with '__' prefix in name, so we could call non-instrumented variant
if needed.
Some files built without kasan instrumentation (e.g. mm/slub.c).
Original mem* function replaced (via #define) with prefixed variants
to disable memory access checks for such files.
Signed-off-by: Andrey Ryabinin <ryabinin.a.a@gmail.com>
Tested-by: Linus Walleij <linus.walleij@linaro.org>
Andrey Ryabinin [Tue, 11 Aug 2015 02:18:17 +0000 (05:18 +0300)]
arm64: move PGD_SIZE definition to pgalloc.h
This will be used by KASAN latter.
Signed-off-by: Andrey Ryabinin <ryabinin.a.a@gmail.com>
Acked-by: Catalin Marinas <catalin.marinas@arm.com>
Andrey Ryabinin [Tue, 11 Aug 2015 02:18:16 +0000 (05:18 +0300)]
arm64: introduce VA_START macro - the first kernel virtual address.
In order to not use lengthy (UL(0xffffffffffffffff) << VA_BITS) everywhere,
replace it with VA_START.
Signed-off-by: Andrey Ryabinin <ryabinin.a.a@gmail.com>
Reviewed-by: Catalin Marinas <catalin.marinas@arm.com>
Andrey Ryabinin [Tue, 11 Aug 2015 02:18:15 +0000 (05:18 +0300)]
x86/kasan, mm: introduce generic kasan_populate_zero_shadow()
Introduce generic kasan_populate_zero_shadow(shadow_start, shadow_end).
This function maps kasan_zero_page to the [shadow_start, shadow_end]
addresses.
This replaces x86_64 specific populate_zero_shadow() and will
be used for ARM64 in follow on patches.
Signed-off-by: Andrey Ryabinin <ryabinin.a.a@gmail.com>
Andrey Ryabinin [Tue, 11 Aug 2015 02:18:14 +0000 (05:18 +0300)]
x86/kasan: define KASAN_SHADOW_OFFSET per architecture
Current definition of KASAN_SHADOW_OFFSET in include/linux/kasan.h
will not work for upcomming arm64, so move it to the arch header.
Signed-off-by: Andrey Ryabinin <ryabinin.a.a@gmail.com>
Andrey Ryabinin [Thu, 2 Jul 2015 09:09:37 +0000 (12:09 +0300)]
x86/kasan: Add message about KASAN being initialized
Print informational message to tell user that kernel
runs with KASAN enabled.
Add a "kasan: " prefix to all messages in kasan_init_64.c.
Signed-off-by: Andrey Ryabinin <a.ryabinin@samsung.com>
Cc: Alexander Popov <alpopov@ptsecurity.com>
Cc: Alexander Potapenko <glider@google.com>
Cc: Andrey Konovalov <adech.fo@gmail.com>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Dmitry Vyukov <dvyukov@google.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Link: http://lkml.kernel.org/r/1435828178-10975-6-git-send-email-a.ryabinin@samsung.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Seung-Woo Kim [Wed, 20 Apr 2016 06:49:49 +0000 (15:49 +0900)]
LOCAL / arm64: defconfig: enable dm_crypt
This patch enables dm_crypt config instead of building as a
module to manage encrypted disk.
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Inki Dae [Mon, 18 Apr 2016 08:11:52 +0000 (17:11 +0900)]
LOCAL: arm64: dts: exynos5433-tm2e: enable mic device node
Signed-off-by: Inki Dae <inki.dae@samsung.com>
Inki Dae [Mon, 18 Apr 2016 07:57:08 +0000 (16:57 +0900)]
drm/exynos: decon: use deferred Trigger mode change
In case of DECON Display, the controller should work with SW trigger mode
even default mode is HW trigger because trigger mode should be changed
on PSR mode of Panel device - there might be some Panel not supported
for the PSR mode.
So this patch makes SW trigger mode to be used until dpms going off
to on again.
Signed-off-by: Inki Dae <inki.dae@samsung.com>
Laurent Pinchart [Fri, 26 Feb 2016 09:51:06 +0000 (11:51 +0200)]
drm/bridge: Make (pre/post) enable/disable callbacks optional
Instead of forcing bridges to implement empty callbacks make them all
optional.
Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: Thierry Reding <treding@nvidia.com>
Daniel Vetter [Fri, 4 Dec 2015 08:45:47 +0000 (09:45 +0100)]
drm/bridge: Improve kerneldoc
Especially document the assumptions and semantics of the callbacks
carefully. Just a warm-up excercise really.
v2: Spelling fixes (Eric).
v3: Consolidate more with existing docs:
- Remove the overview section explaining the bridge funcs, that's
now all in the drm_bridge_funcs kerneldoc in much more detail.
- Use & to reference structs so that kerneldoc automatically inserts
hyperlinks.
v4: Review from Thierry.
Cc: Eric Anholt <eric@anholt.net>
Cc: Archit Taneja <architt@codeaurora.org>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Archit Taneja <architt@codeaurora.org> (v3)
Link: http://patchwork.freedesktop.org/patch/msgid/1449218769-16577-7-git-send-email-daniel.vetter@ffwll.ch
Reviewed-by: Thierry Reding <treding@nvidia.com>
Archit Taneja [Thu, 21 May 2015 05:33:17 +0000 (11:03 +0530)]
drm/DocBook: Add more drm_bridge documentation
Add DOC sections giving an overview of drm_bridge and how to fill up the
drm_bridge_funcs ops. Add these to drm.tpml in DocBook.
Add headerdocs for funcs in drm_bridge.c that don't have them yet.
Signed-off-by: Archit Taneja <architt@codeaurora.org>
[danvet: Amend kerneldoc as discussed with Archit.]
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Archit Taneja [Thu, 14 Apr 2016 05:50:15 +0000 (14:50 +0900)]
drm: bridge: Allow daisy chaining of bridges
Allow drm_bridge objects to link to each other in order to form an encoder
chain. The requirement for creating a chain of bridges comes because the
MSM drm driver uses up its encoder and bridge objects for blocks within
the SoC itself. There isn't anything left to use if the SoC display output
is connected to an external encoder IC. Having an additional bridge
connected to the existing bridge helps here. In general, it is possible for
platforms to have multiple devices between the encoder and the
connector/panel that require some sort of configuration.
We create drm bridge helper functions corresponding to each op in
'drm_bridge_funcs'. These helpers call the corresponding
'drm_bridge_funcs' op for the entire chain of bridges. These helpers are
used internally by drm_atomic_helper.c and drm_crtc_helper.c.
The drm_bridge_enable/pre_enable helpers execute enable/pre_enable ops of
the bridge closet to the encoder, and proceed until the last bridge in the
chain is enabled. The same holds for drm_bridge_mode_set/mode_fixup
helpers. The drm_bridge_disable/post_disable helpers disable the last
bridge in the chain first, and proceed until the first bridge in the chain
is disabled.
drm_bridge_attach() remains the same. As before, the driver calling this
function should make sure it has set the links correctly. The order in
which the bridges are connected to each other determines the order in which
the calls are made. One requirement is that every bridge in the chain
should point the parent encoder object. This is required since bridge
drivers expect a valid encoder pointer in drm_bridge. For example, consider
a chain where an encoder's output is connected to bridge1, and bridge1's
output is connected to bridge2:
/* Like before, attach bridge to an encoder */
bridge1->encoder = encoder;
ret = drm_bridge_attach(dev, bridge1);
..
/*
* set the first bridge's 'next' bridge to bridge2, set its encoder
* as bridge1's encoder
*/
bridge1->next = bridge2
bridge2->encoder = bridge1->encoder;
ret = drm_bridge_attach(dev, bridge2);
...
...
This method of bridge chaining isn't intrusive and existing drivers that
use drm_bridge will behave the same way as before. The bridge helpers also
cleans up the atomic and crtc helper files a bit.
Reviewed-by: Jani Nikula <jani.nikula@linux.intel.com>
Reviewed-by: Rob Clark <robdclark@gmail.com>
Reviewed-by: Daniel Vetter <daniel@ffwll.ch>
Signed-off-by: Archit Taneja <architt@codeaurora.org>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Inki Dae <inki.dae@samsung.com>
Inki Dae [Tue, 12 Apr 2016 08:43:22 +0000 (17:43 +0900)]
Local: arm64: dts: exynos5433-tm2: enable mic device node
Signed-off-by: Inki Dae <inki.dae@samsung.com>
Inki Dae [Tue, 12 Apr 2016 08:42:30 +0000 (17:42 +0900)]
drm/exynos: mic: add component support
Signed-off-by: Inki Dae <inki.dae@samsung.com>
Inki Dae [Tue, 12 Apr 2016 02:31:21 +0000 (11:31 +0900)]
drm/exynos: decon: wait for vsync after dma channel clear
This patch removes temparary codes which used sleep function
to wait for the completion of vsync, and uses wait_event_timeout
function instead.
Signed-off-by: Inki Dae <inki.dae@samsung.com>
Inki Dae [Wed, 30 Mar 2016 08:49:51 +0000 (17:49 +0900)]
ARM: dts: exynos5433: add sysreg property for display block
This patch adds a property for display block sysreg.
Signed-off-by: Inki Dae <inki.dae@samsung.com>
Inki Dae [Wed, 30 Mar 2016 08:46:22 +0000 (17:46 +0900)]
drm/exynos: decon: add sysreg support
This patch adds sysreg support to control display block,
and makes te unmask bit of display block to be set
according to trigger mode defined already.
This is required for HW trigger mode support.
Signed-off-by: Inki Dae <inki.dae@samsung.com>
Inki Dae [Tue, 12 Apr 2016 02:27:50 +0000 (11:27 +0900)]
drm/exynos: decon: add HW trigger mode support
This patch adds hardware trigger mode support on command mode.
And also it cleans up decon_setup_trigger function which identifed
trigger mode checking display type.
However, the trigger mode is a common part of two types - DISPLAY and HDMI
so it can be set according to trigger mode type given.
Signed-off-by: Inki Dae <inki.dae@samsung.com>
Inki Dae [Wed, 30 Mar 2016 08:03:52 +0000 (17:03 +0900)]
drm/exynos: decon: make sure to complete scanout before released
This patch makes framebuffer to be scaned out completely
before drm driver is released. This resolves the page fault issue
with IOMMU when released.
Signed-off-by: Inki Dae <inki.dae@samsung.com>
Inki Dae [Wed, 30 Mar 2016 07:54:57 +0000 (16:54 +0900)]
drm/exynos: decon: do not call decon_setup_trigger function unnecessary
This patch makes decon_setup_trigger function to be called only at
decon_commit function and remove the calls from other functions.
Signed-off-by: Inki Dae <inki.dae@samsung.com>
Seung-Woo Kim [Thu, 24 Mar 2016 05:19:13 +0000 (14:19 +0900)]
LOCAL / arm64: defconfig: enable joystick interface and dev
This enables joystick interface and dev config options from
defconfig.
It is requested from windows input and bt part.
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Seung-Woo Kim [Thu, 24 Mar 2016 05:17:36 +0000 (14:17 +0900)]
LOCAL / arm64: defconfig: sync with 4.1 kernel
This patch makes sync for defconfig with 4.1 kernel.
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Sylwester Nawrocki [Thu, 3 Mar 2016 15:27:59 +0000 (16:27 +0100)]
fimc-is: Rename "is fail" to "failed"
Let's correct these phrases before I start believing they are
proper grammatical constructs...
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Sylwester Nawrocki [Fri, 11 Mar 2016 15:08:37 +0000 (16:08 +0100)]
fimc-is: Add proper implementation of fimc_is_ischain_forcedown()
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Sylwester Nawrocki [Thu, 10 Mar 2016 16:46:47 +0000 (17:46 +0100)]
fimc-is: MCUCTL register definition cleanup
Lots of (mostly unused) postfix-indexed macro definitions
are now replaced with parametric definitions.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Sylwester Nawrocki [Thu, 10 Mar 2016 16:24:27 +0000 (17:24 +0100)]
fimc-is: Remove unused data structure declaration
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Sylwester Nawrocki [Thu, 10 Mar 2016 16:43:00 +0000 (17:43 +0100)]
fimc-is: Clear all MCUCTL register in the power up sequence
When the ISP, CAM{0,1} power domains are always on it is required
to clear MCUCTL registers in the ISP power up sequence, otherwise
the front camera is not working properly if previously the rear
camera pipeline was used. The original code relied on the MCUCTL
registers being reset to default values after the ISP power domain
switch off/on cycle.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Sylwester Nawrocki [Fri, 4 Mar 2016 16:56:32 +0000 (17:56 +0100)]
fimc-is: Reconfigure more muxes to oscclk in the power off sequence
We don't switch off CAM1, CAM0, ISP power domain so reconfigure
more muxes to their default after reset state duriong power off
sequence.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Sylwester Nawrocki [Mon, 29 Feb 2016 15:03:26 +0000 (16:03 +0100)]
fimc-is: Workaround for ACLK_CAM1_552_USER configuration issues
For some reason "mout_aclk_cam1_552_user" clock reconfiguration from
"oscclk" to "aclk_cam1_552" breaks the front camera operation (often
only empty buffer are dequeued). But it is required for the rear
camera. Until the root cause is found reconfigure the mux conditionally
only for the rear sensor operation.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Sylwester Nawrocki [Thu, 3 Mar 2016 15:30:54 +0000 (16:30 +0100)]
fimc-is: Fix compiler warning
n file included from drivers/media/platform/exynos/fimc-is/fimc-is-companion-dt.c:23:0:
drivers/media/platform/exynos/fimc-is/fimc-is-dt.h:36:58: warning: 'struct fimc_is_core' declared inside parameter list
int fimc_is_parse_children_dt(struct device *dev, struct fimc_is_core *core);
^
drivers/media/platform/exynos/fimc-is/fimc-is-dt.h:36:58: warning: its scope is only this definition or declaration, which is probably not what you want
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Sylwester Nawrocki [Wed, 2 Mar 2016 14:39:51 +0000 (15:39 +0100)]
spi: exynos5433-isp: Add H/W initialization in runtime_resume callback
Not sure what the FIMC-IS firmware does but without these changes
SPI is not working on the second run of the rear sensor processing
pipeline. Also the controler's state may be lost when ISP power
domain is switched off so it must be reinitialized in runtime_resume
callback.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Sylwester Nawrocki [Wed, 2 Mar 2016 14:41:06 +0000 (15:41 +0100)]
i2c: i2c-s3c2401: hack for for ISP_I2C controllers
This is required to ensure proper operation of the ISP I2C
controller from the Linux driver and the FIMC-IS firmware
level.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Sylwester Nawrocki [Fri, 26 Feb 2016 16:33:50 +0000 (17:33 +0100)]
fimc-is: Add setting of vendorSpecific2[0] metadata structure field
vendorSpecific2[0] value pattern depends on the fimc-is firmware
revision. Move setting up of this field to the kernel as there is
all information required for this.
The driver will update the field accordingly only if user space
leaves it cleared.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Sylwester Nawrocki [Fri, 26 Feb 2016 16:02:46 +0000 (17:02 +0100)]
fimc-is: Workaround for CLK_MOUT_ACLK_CAM1_552_USER clock
When CLK_MOUT_ACLK_CAM1_552_USER clock is properly defined
in clk-exynos5433.c re-parenting commented out in this patch
causes that only empty buffers can be dequeued from the scaler
for front camera. So re-parenting is disabled for now until
we can address this issue in a better way.
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Kazimierz Krosman [Tue, 16 Feb 2016 16:32:15 +0000 (17:32 +0100)]
Fix: bug that allows adding more dev than max minor number
Signed-off-by: Kazimierz Krosman <k.krosman@samsung.com>
Andi Shyti [Wed, 3 Feb 2016 09:50:32 +0000 (18:50 +0900)]
input: touchscreen: fts: added touch key functionality
The ST Microelectronics FTM3BD56 touch screen device has a key
functinality to simulate the "phone" and the "back" button from
Android phone devices.
This patch adds this functionality as boards like TM2E are
using it instead of having separate device for the touch key.
The patch adds in the device tree a boolean property
"touch-key-connected" that, if present, enables the touch
property in the device and in the driver.
The driver, itself, when "touch-key-connected" present, generates
an input event that reports actions on the "phone" and on the
"back" key:
when the phone button is pressed or released:
type EV_KEY
code KEY_PHONE (169)
value 1/0 (pressed or released)
when the back button is pressed or released:
type EV_KEY
code KEY_BACK (158)
value 1/0 (pressed or released)
When discovering the deice, look for event name "sec_touchkey".
Signed-off-by: Andi Shyti <andi.shyti@samsung.com>
Andi Shyti [Wed, 3 Feb 2016 09:47:39 +0000 (18:47 +0900)]
dts: exynos5433: TM2E: remove cypress touchkey
Remove cypress touchkey as the device is not present on TM2E
board.
Signed-off-by: Andi Shyti <andi.shyti@samsung.com>
Andi Shyti [Wed, 3 Feb 2016 09:45:01 +0000 (18:45 +0900)]
input: fts_ts: remove redundant event counting
... as it is not useful for anything.
Signed-off-by: Andi Shyti <andi.shyti@samsung.com>
Paul Osmialowski [Wed, 23 Sep 2015 16:04:13 +0000 (18:04 +0200)]
kmsg: selftests
This patch adds selftests framework and four test scenarios for kmsg.
The framework shape and code was inspired by similar selftests framework
for kdbus.
Change-Id: I4453105186c90430dcdb59d592392fbac05b42f5
Signed-off-by: Paul Osmialowski <p.osmialowsk@samsung.com>
Marcin Niesluchowski [Thu, 21 May 2015 14:24:30 +0000 (16:24 +0200)]
kmsg: add ioctl for kmsg* devices operating on buffers
There is no possibility to clear additional kmsg buffers,
get size of them or know what size should be passed to read
file operation (too small size causes it to retrun -EINVAL).
Add following ioctls which solve those issues:
* KMSG_CMD_GET_BUF_SIZE
* KMSG_CMD_GET_READ_SIZE_MAX
* KMSG_CMD_CLEAR
Change-Id: I7ee4c54495f6c4fd1458fd2998ffae0f3a8866c0
Signed-off-by: Marcin Niesluchowski <m.niesluchow@samsung.com>
Marcin Niesluchowski [Thu, 18 Jun 2015 09:31:00 +0000 (11:31 +0200)]
kmsg: add ioctl for adding and deleting kmsg* devices
There is no possibility to add/delete kmsg* buffers from userspace.
Adds following ioctl for main kmsg device adding and deleting
additional kmsg devices:
* KMSG_CMD_BUFFER_ADD
* KMSG_CMD_BUFFER_DEL
Change-Id: Ibc3c959957a545b09de4bbcb35533b690ba31fb5
Signed-off-by: Marcin Niesluchowski <m.niesluchow@samsung.com>
Marcin Niesluchowski [Mon, 27 Apr 2015 09:20:34 +0000 (11:20 +0200)]
kmsg: add predefined _PID, _TID, _COMM keywords to kmsg* log dict
kmsg* devices write operation wrote no dict along with message
Due to usage of kmsg devices in userspace dict has been added
identifying pid, tid and comm of writing process.
Change-Id: I82fec61b012d3df5a5d5e4bd5c9999d92c32496d
Signed-off-by: Marcin Niesluchowski <m.niesluchow@samsung.com>
Signed-off-by: Karol Lewandowski <k.lewandowsk@samsung.com>
Marcin Niesluchowski [Mon, 20 Apr 2015 11:03:10 +0000 (13:03 +0200)]
kmsg: add function for adding and deleting additional buffers
Additional kmsg buffers should be created and deleted dynamically.
Adding two functions
* kmsg_sys_buffer_add() creates additional kmsg buffer returning minor
* kmsg_sys_buffer_del() deletes one based on provided minor
Change-Id: Ibb85543b830ecd186e8cf7ebdf560f72c0bba83c
Signed-off-by: Marcin Niesluchowski <m.niesluchow@samsung.com>
Marcin Niesluchowski [Mon, 20 Jul 2015 12:52:06 +0000 (14:52 +0200)]
kmsg: add additional buffers support to memory class
Memory class does not support additional kmsg buffers.
Add additional kmsg buffers support to:
* devnode() callback of "mem" class
* file operations of major "mem" character device
Change-Id: I15b6c79435b4dc18422a9bd6836bd9c7a87ad60a
Signed-off-by: Marcin Niesluchowski <m.niesluchow@samsung.com>
Signed-off-by: Karol Lewandowski <k.lewandowsk@samsung.com>
Marcin Niesluchowski [Wed, 29 Apr 2015 17:37:05 +0000 (19:37 +0200)]
kmsg: introduce additional kmsg devices support
kmsg device provides operations on cyclic logging buffer used mainly
by kernel but also in userspace by privileged processes.
Additional kmsg devices keep the same log format but may be added
dynamically with custom size.
Change-Id: I52c28310197594888621000bb5be933173c3031d
Signed-off-by: Marcin Niesluchowski <m.niesluchow@samsung.com>