From: Mark Brown <broonie(a)linaro.org>
Systems with the common clock API need clk_prepare() as well as the enable
step.
Signed-off-by: Mark Brown <broonie(a)linaro.org>
---
drivers/usb/phy/phy-nop.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/usb/phy/phy-nop.c b/drivers/usb/phy/phy-nop.c
index f52b7f8..6988c15 100644
--- a/drivers/usb/phy/phy-nop.c
+++ b/drivers/usb/phy/phy-nop.c
@@ -80,7 +80,7 @@ static int nop_init(struct usb_phy *phy)
}
if (!IS_ERR(nop->clk))
- clk_enable(nop->clk);
+ clk_prepare_enable(nop->clk);
if (!IS_ERR(nop->reset)) {
/* De-assert RESET */
@@ -102,7 +102,7 @@ static void nop_shutdown(struct usb_phy *phy)
}
if (!IS_ERR(nop->clk))
- clk_disable(nop->clk);
+ clk_disable_unprepare(nop->clk);
if (!IS_ERR(nop->vcc)) {
if (regulator_disable(nop->vcc))
--
1.8.4.rc1
Many serial driver triggers a lockdep warning for if tty_flip_buffer_push() is
called with uart_port->lock locked. This never shows up on UP kernels and comes
up only on SMP kernels.
Crash looks like this (produced with samsung.c driver):
-----
[<c0014d58>] (unwind_backtrace+0x0/0xf8) from [<c0011908>] (show_stack+0x10/0x14)
[<c0011908>] (show_stack+0x10/0x14) from [<c035da34>] (dump_stack+0x6c/0xac)
[<c035da34>] (dump_stack+0x6c/0xac) from [<c01b59ac>] (do_raw_spin_unlock+0xc4/0xd8)
[<c01b59ac>] (do_raw_spin_unlock+0xc4/0xd8) from [<c03627e4>] (_raw_spin_unlock_irqrestore+0xc/0)
[<c03627e4>] (_raw_spin_unlock_irqrestore+0xc/0x38) from [<c020a1a8>] (s3c24xx_serial_rx_chars+0)
[<c020a1a8>] (s3c24xx_serial_rx_chars+0x12c/0x260) from [<c020aae8>] (s3c64xx_serial_handle_irq+)
[<c020aae8>] (s3c64xx_serial_handle_irq+0x48/0x60) from [<c006aaa0>] (handle_irq_event_percpu+0x)
[<c006aaa0>] (handle_irq_event_percpu+0x50/0x194) from [<c006ac20>] (handle_irq_event+0x3c/0x5c)
[<c006ac20>] (handle_irq_event+0x3c/0x5c) from [<c006d864>] (handle_fasteoi_irq+0x80/0x13c)
[<c006d864>] (handle_fasteoi_irq+0x80/0x13c) from [<c006a4a4>] (generic_handle_irq+0x20/0x30)
[<c006a4a4>] (generic_handle_irq+0x20/0x30) from [<c000f454>] (handle_IRQ+0x38/0x94)
[<c000f454>] (handle_IRQ+0x38/0x94) from [<c0008538>] (gic_handle_irq+0x34/0x68)
[<c0008538>] (gic_handle_irq+0x34/0x68) from [<c00123c0>] (__irq_svc+0x40/0x70)
Exception stack(0xc04cdf70 to 0xc04cdfb8)
df60: 00000000 00000000 0000166e 00000000
df80: c04cc000 c050278f c050278f 00000001 c04d444c 410fc0f4 c03649b0 00000000
dfa0: 00000001 c04cdfb8 c000f758 c000f75c 60070013 ffffffff
[<c00123c0>] (__irq_svc+0x40/0x70) from [<c000f75c>] (arch_cpu_idle+0x28/0x30)
[<c000f75c>] (arch_cpu_idle+0x28/0x30) from [<c0054888>] (cpu_startup_entry+0x5c/0x148)
[<c0054888>] (cpu_startup_entry+0x5c/0x148) from [<c0497aa4>] (start_kernel+0x334/0x38c)
BUG: spinlock lockup suspected on CPU#0, kworker/0:1/360
lock: s3c24xx_serial_ports+0x1d8/0x370, .magic: dead4ead, .owner: <none>/-1, .owner_cpu: -1
CPU: 0 PID: 360 Comm: kworker/0:1 Not tainted 3.11.0-rc6-next-20130819-00003-g75485f1 #2
Workqueue: events flush_to_ldisc
[<c0014d58>] (unwind_backtrace+0x0/0xf8) from [<c0011908>] (show_stack+0x10/0x14)
[<c0011908>] (show_stack+0x10/0x14) from [<c035da34>] (dump_stack+0x6c/0xac)
[<c035da34>] (dump_stack+0x6c/0xac) from [<c01b581c>] (do_raw_spin_lock+0x100/0x17c)
[<c01b581c>] (do_raw_spin_lock+0x100/0x17c) from [<c03628a0>] (_raw_spin_lock_irqsave+0x20/0x28)
[<c03628a0>] (_raw_spin_lock_irqsave+0x20/0x28) from [<c0203224>] (uart_start+0x18/0x34)
[<c0203224>] (uart_start+0x18/0x34) from [<c01ef890>] (__receive_buf+0x4b4/0x738)
[<c01ef890>] (__receive_buf+0x4b4/0x738) from [<c01efb44>] (n_tty_receive_buf2+0x30/0x98)
[<c01efb44>] (n_tty_receive_buf2+0x30/0x98) from [<c01f2ba8>] (flush_to_ldisc+0xec/0x138)
[<c01f2ba8>] (flush_to_ldisc+0xec/0x138) from [<c0031af0>] (process_one_work+0xfc/0x348)
[<c0031af0>] (process_one_work+0xfc/0x348) from [<c0032138>] (worker_thread+0x138/0x37c)
[<c0032138>] (worker_thread+0x138/0x37c) from [<c0037a7c>] (kthread+0xa4/0xb0)
[<c0037a7c>] (kthread+0xa4/0xb0) from [<c000e5f8>] (ret_from_fork+0x14/0x3c)
-----
This patchset modifies these drivers to release the port lock before calling
tty_flip_buffer_push() and reacquire it after the call.
Similar stuff was already done for few other drivers in the past, like:
commit 2389b272168ceec056ca1d8a870a97fa9c26e11a
Author: Thomas Gleixner <tglx(a)linutronix.de>
Date: Tue May 29 21:53:50 2007 +0100
[ARM] 4417/1: Serial: Fix AMBA drivers locking
This is build tested for all drivers and tested on Samsung's Arndale board for
samsung.c driver. Rebased over linux-next (Problem was reproduced on this
branch):
commit 1e712b0818569846d6b926ecb6bf32b3dea73609
Author: Stephen Rothwell <sfr(a)canb.auug.org.au>
Date: Fri Aug 16 17:06:26 2013 +1000
Add linux-next specific files for 20130816
Signed-off-by: Stephen Rothwell <sfr(a)canb.auug.org.au>
Cc: Bryan Huntsman <bryanh(a)codeaurora.org>
Cc: Daniel Walker <dwalker(a)fifo99.com>
Cc: David Brown <davidb(a)codeaurora.org>
Cc: Stephen Warren <swarren(a)wwwdotorg.org>
Cc: Tobias Klauser <tklauser(a)distanz.ch>
Cc: Tony Prisk <linux(a)prisktech.co.nz>
Viresh Kumar (25):
tty: serial: altera_jtag: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: altera: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: apbuart: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: ar933x: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: arc: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: bcm63xx: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: bfin_sport: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: efm32: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: icom: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: lpc32xx_hs: don't call tty_flip_buffer_push() twice
tty: serial: lpc32xx_hs: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: m32r_sio: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: mcf: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: mfd: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: mpsc: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: msm: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: netx: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: nwpserial: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: pnx8xxx: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: rp2: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: sa1100: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: samsung: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: tegra: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: sirfsoc: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: vt8500: drop uart_port->lock before calling
tty_flip_buffer_push()
drivers/tty/serial/altera_jtaguart.c | 2 ++
drivers/tty/serial/altera_uart.c | 2 ++
drivers/tty/serial/apbuart.c | 2 ++
drivers/tty/serial/ar933x_uart.c | 2 ++
drivers/tty/serial/arc_uart.c | 2 ++
drivers/tty/serial/bcm63xx_uart.c | 2 ++
drivers/tty/serial/bfin_sport_uart.c | 5 +++--
drivers/tty/serial/efm32-uart.c | 4 ++--
drivers/tty/serial/icom.c | 3 +++
drivers/tty/serial/lpc32xx_hs.c | 7 ++++---
drivers/tty/serial/m32r_sio.c | 3 +++
drivers/tty/serial/mcf.c | 2 ++
drivers/tty/serial/mfd.c | 14 ++++++++++----
drivers/tty/serial/mpsc.c | 11 ++++++++---
drivers/tty/serial/msm_serial.c | 5 +++++
drivers/tty/serial/netx-serial.c | 6 ++++--
drivers/tty/serial/nwpserial.c | 3 +++
drivers/tty/serial/pnx8xxx_uart.c | 3 +++
drivers/tty/serial/rp2.c | 2 ++
drivers/tty/serial/sa1100.c | 3 +++
drivers/tty/serial/samsung.c | 5 ++++-
drivers/tty/serial/serial-tegra.c | 10 ++++++++--
drivers/tty/serial/sirfsoc_uart.c | 3 +++
drivers/tty/serial/vt8500_serial.c | 2 ++
24 files changed, 84 insertions(+), 19 deletions(-)
--
1.7.12.rc2.18.g61b472e
Hi Rafael,
I am almost done with cleanup of drivers and am back at cpufreq core.. :)
I got to this structure: struct cpufreq_real_policy;
And I am not able to understand what's the need for this structure?
Can you let me know? Before I try to get rid of it :)
--
viresh
This patch adds a Kconfig dependency on an ARCH_VEXPRESS(it is for
both ARM and ARM64) or ARCH_VEXPRESS_CA9X being available before
VEXPRESS_CONFIG can be enabled. Without this patch,build system
can lead to issues. This was discovered during randconfig testing,
in which VEXPRESS_CONFIG was enabled w/o ARCH_VEXPRESS or VEXPRESS_CONFIG
being enabled,leading to the following error:
CC drivers/mfd/vexpress-config.o
drivers/mfd/vexpress-config.c: In function ‘__vexpress_config_func_get’:
drivers/mfd/vexpress-config.c:117:4: error: implicit declaration of function
‘of_find_node_by_phandle’ [-Werror=implicit-function-declaration]
bridge_node = of_find_node_by_phandle(
^
drivers/mfd/vexpress-config.c:117:16: warning: assignment makes pointer from
integer without a cast [enabled by default]
bridge_node = of_find_node_by_phandle(
Signed-off-by: Manjunath Goudar <manjunath.goudar(a)linaro.org>
Cc: Arnd Bergmann <arnd(a)arndb.de>
Cc: Deepak Saxena <dsaxena(a)linaro.org>
Cc: Samuel Ortiz <sameo(a)linux.intel.com>
Cc: Lee Jones <lee.jones(a)linaro.org>
---
drivers/mfd/Kconfig | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/mfd/Kconfig b/drivers/mfd/Kconfig
index 633ee43..c9202f6 100644
--- a/drivers/mfd/Kconfig
+++ b/drivers/mfd/Kconfig
@@ -1174,7 +1174,7 @@ endmenu
config VEXPRESS_CONFIG
bool "ARM Versatile Express platform infrastructure"
- depends on ARM || ARM64
+ depends on ARCH_VEXPRESS || ARCH_VEXPRESS_CA9X4
help
Platform configuration infrastructure for the ARM Ltd.
Versatile Express.
--
1.7.9.5
From: root <root(a)si-cspbld63.lge.net>
This patch adds a omap1510_fpga_init_irq() inline dummy implementations
in arch/arm/mach-omap1/common.h. Without this patch,build system can
lead to issues. This was discovered during randconfig testing,in which
other than CONFIG_ARCH_OMAP15XX was enabled the leading to the following
error:
CC arch/arm/mach-omap1/board-innovator.o
arch/arm/mach-omap1/board-innovator.c: In function ‘innovator_init’:
arch/arm/mach-omap1/board-innovator.c:377:3: error: implicit declaration of
function ‘omap1510_fpga_init_irq’ [-Werror=implicit-function-declaration]
cc1: some warnings being treated as errors
make[1]: *** [arch/arm/mach-omap1/board-innovator.o] Error 1
make: *** [arch/arm/mach-omap1] Error 2
Signed-off-by: Manjunath Goudar <manjunath.goudar(a)linaro.org>
Cc: Arnd Bergmann <arnd(a)arndb.de>
Cc: Deepak Saxena <dsaxena(a)linaro.org>
Cc: Linus Walleij <linus.walleij(a)linaro.org>
Cc: Tony Lindgren <tony(a)atomide.com>
Cc: linux-omap(a)vger.kernel.org
---
arch/arm/mach-omap1/common.h | 3 +++
1 file changed, 3 insertions(+)
diff --git a/arch/arm/mach-omap1/common.h b/arch/arm/mach-omap1/common.h
index abec019..732f8ee 100644
--- a/arch/arm/mach-omap1/common.h
+++ b/arch/arm/mach-omap1/common.h
@@ -46,6 +46,9 @@ static inline void omap7xx_map_io(void)
void omap1510_fpga_init_irq(void);
void omap15xx_map_io(void);
#else
+static inline void omap1510_fpga_init_irq(void)
+{
+}
static inline void omap15xx_map_io(void)
{
}
--
1.8.1.2
Hi Rafael,
Hopefully this is the last patch for 3.12 for ARM CPUFreq subsystem.
The following changes since commit b36f4be3de1b123d8601de062e7dbfc904f305fb:
Linux 3.11-rc6 (2013-08-18 14:36:53 -0700)
are available in the git repository at:
git://git.linaro.org/people/vireshk/linux.git cpufreq-fixes
for you to fetch changes up to b192b910f3832793082c1a18262c4da0efe121ae:
cpufreq: tegra: fix the wrong clock name (2013-08-23 21:58:28 +0530)
----------------------------------------------------------------
Joseph Lo (1):
cpufreq: tegra: fix the wrong clock name
drivers/cpufreq/tegra-cpufreq.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
Hi Tommi,
I am looking for info and help on the libunwind API.
What I am trying to achieve is to allow the callchain feature on perf for
ARM (v7 to start with, then ARMv8), from the DWARF info found in the
.debug_frame section.
>From the source code in tools/perf I have added the call to
dwarf_find_debug_frame to load and parse the debug info from .debug_frame.
This works correctly, all IP ranges are found from the debug code (test
program and libraries). Then at some point I get an assertion: 'perf:
dwarf/Gparser.c:459: fetch_proc_info: Assertion `c->pi.unwind_info'
failed.' At that point c->pi is NULL. Cf. below for more info.
It looks like I am not using the libunwind API as it should, so that the
perf code apparently builds a list of IP ranges to resolve but cannot use
it later on to gather statistics on the runtime info.
Any idea on how to progress? I am also looking at the *_proc_info API of
libunwind.
Here is the patch I am using below.
Regards,
Jean
---
Log:
_Uarm_step: calling dwarf_step(ip=0x8464, c->dwarf@0xbee150f8,
c->dwarf.pi@0xb2bc0008)
unwind: find_proc_info dso /home/linaro/perf-libunwind/test_app/stress_bt
read_unwind_spec_debug_frame: .debug_frame offset=9304
opened file '/home/linaro/perf-libunwind/test_app/stress_bt'. Section
header at offset 18152
read 3160 bytes of .debug_frame from offset 9304
...
_ULarm_step: calling dwarf_step(ip=0xb6e6e764, c->dwarf@0xbee07508,
c->dwarf.pi@0xb6e955c0)
_ULarm_find_proc_info: looking for IP=0xb6e6e763
opened file '/usr/lib/arm-linux-gnueabihf/libunwind.so.8'. Section header
at offset 513260
read 17072 bytes of .debug_frame from offset 451836
_ULarm_dwarf_search_unwind_table: looking for IP=0xb6e6e763
_ULarm_find_proc_info returns 0
...
perf: dwarf/Gparser.c:459: fetch_proc_info: Assertion `c->pi.unwind_info'
failed.
---
Patch to the kernel source:
diff --git a/tools/perf/util/unwind.c b/tools/perf/util/unwind.c
index 958723b..dd97688 100644
--- a/tools/perf/util/unwind.c
+++ b/tools/perf/util/unwind.c
@@ -39,6 +39,14 @@ UNW_OBJ(dwarf_search_unwind_table) (unw_addr_space_t as,
#define dwarf_search_unwind_table UNW_OBJ(dwarf_search_unwind_table)
+extern int
+UNW_OBJ(dwarf_find_debug_frame) (int found, unw_dyn_info_t *di_debug,
+ unw_word_t ip, unw_word_t segbase,
+ const char* obj_name, unw_word_t start,
+ unw_word_t end);
+
+#define dwarf_find_debug_frame UNW_OBJ(dwarf_find_debug_frame)
+
#define DW_EH_PE_FORMAT_MASK 0x0f /* format of the encoded value */
#define DW_EH_PE_APPL_MASK 0x70 /* how the value is to be applied */
@@ -245,8 +253,9 @@ static int unwind_spec_ehframe(struct dso *dso,
struct machine *machine,
return 0;
}
-static int read_unwind_spec(struct dso *dso, struct machine *machine,
- u64 *table_data, u64 *segbase, u64 *fde_count)
+static int read_unwind_spec_eh_frame(struct dso *dso, struct machine
*machine,
+ u64 *table_data, u64 *segbase,
+ u64 *fde_count)
{
int ret = -EINVAL, fd;
u64 offset;
@@ -255,18 +264,40 @@ static int read_unwind_spec(struct dso *dso,
struct machine *machine,
if (fd < 0)
return -EINVAL;
+ /* Check the .eh_frame section for unwinding info */
offset = elf_section_offset(fd, ".eh_frame_hdr");
close(fd);
- if (offset)
+ if (offset) {
+ fprintf(stderr, "%s: .eh_frame offset=%llu\n", __func__, offset);
ret = unwind_spec_ehframe(dso, machine, offset,
table_data, segbase,
fde_count);
+ }
- /* TODO .debug_frame check if eh_frame_hdr fails */
return ret;
}
+static int read_unwind_spec_debug_frame(struct dso *dso,
+ struct machine *machine,
+ u64 *segbase)
+{
+ int fd = dso__data_fd(dso, machine);
+ if (fd < 0)
+ return -EINVAL;
+
+ /* Check the .debug_frame section for unwinding info */
+ *segbase = elf_section_offset(fd, ".debug_frame");
+ close(fd);
+
+ fprintf(stderr, "%s: .debug_frame offset=%llu\n", __func__, *segbase);
+
+ if (!segbase)
+ return -EINVAL;
+
+ return 0;
+}
+
static struct map *find_map(unw_word_t ip, struct unwind_info *ui)
{
struct addr_location al;
@@ -289,22 +320,32 @@ find_proc_info(unw_addr_space_t as, unw_word_t
ip, unw_proc_info_t *pi,
if (!map || !map->dso)
return -EINVAL;
- pr_debug("unwind: find_proc_info dso %s\n", map->dso->name);
+ fprintf(stderr, "unwind: find_proc_info dso %s\n", map->dso->name);
+
+ /* Check the .eh_frame section for unwinding info */
+ if (!read_unwind_spec_eh_frame(map->dso, ui->machine,
+ &table_data, &segbase, &fde_count)) {
+ memset(&di, 0, sizeof(di));
+ di.format = UNW_INFO_FORMAT_REMOTE_TABLE;
+ di.start_ip = map->start;
+ di.end_ip = map->end;
+ di.u.rti.segbase = map->start + segbase;
+ di.u.rti.table_data = map->start + table_data;
+ di.u.rti.table_len = fde_count * sizeof(struct table_entry)
+ / sizeof(unw_word_t);
+ return dwarf_search_unwind_table(as, ip, &di, pi,
+ need_unwind_info, arg);
+ }
- if (read_unwind_spec(map->dso, ui->machine,
- &table_data, &segbase, &fde_count))
- return -EINVAL;
+ /* Check the .debug_frame section for unwinding info */
+ if (!read_unwind_spec_debug_frame(map->dso, ui->machine, &segbase)) {
+ memset(&di, 0, sizeof(di));
+ if (dwarf_find_debug_frame(0, &di, ip, segbase, map->dso->name,
+ map->start, map->end))
+ return 0;
+ }
- memset(&di, 0, sizeof(di));
- di.format = UNW_INFO_FORMAT_REMOTE_TABLE;
- di.start_ip = map->start;
- di.end_ip = map->end;
- di.u.rti.segbase = map->start + segbase;
- di.u.rti.table_data = map->start + table_data;
- di.u.rti.table_len = fde_count * sizeof(struct table_entry)
- / sizeof(unw_word_t);
- return dwarf_search_unwind_table(as, ip, &di, pi,
- need_unwind_info, arg);
+ return -EINVAL;
}
static int access_fpreg(unw_addr_space_t __maybe_unused as,
This patchset does the following 3 things:
1) Fixes the RTC DT node name for Exynos5250
2) Update the "status" property of RTC DT node for Exynos5250 SoC
3) Adds RTC DT node to Exynos5420 SoC
changes since v5:
- Fixed the RTC DT node name for Exynos5250 board files also,
because otherwise it breaks RTC support in bisections.
changes since v4:
- removed "status" property of RTC DT node from exynos5250 board dts files
changes since v3:
- split the 5250 related modifications into 2 separate patch as
suggested by Tomasz Figa <t.figa(a)samsung.com>
changes since v2:
- split the 5250 related modifications into a separate patch.
- placed the RTC node as per the alphabetical order in the DTS file as
suggested by Kukjin Kim <kgene(a)kernel.org>.
changes since v1:
- made DT node status as "okay" in the dtsi file itself.
Vikas Sajjan (3):
ARM: dts: Fix the RTC DT node name for Exynos5250
ARM: dts: Update the "status" property of RTC DT node for Exynos5250
SoC
ARM: dts: Add RTC DT node to Exynos5420 SoC
arch/arm/boot/dts/exynos5.dtsi | 2 +-
arch/arm/boot/dts/exynos5250-arndale.dts | 4 ----
arch/arm/boot/dts/exynos5250-snow.dts | 4 ----
arch/arm/boot/dts/exynos5250.dtsi | 3 ++-
arch/arm/boot/dts/exynos5420.dtsi | 6 ++++++
5 files changed, 9 insertions(+), 10 deletions(-)
--
1.7.9.5
The Versatile Express TC2 board, which we use as our main emulated
platform in QEMU, defines 160+32 == 192 interrupts, so limiting the
number of interrupts to 128 is not quite going to cut it for real board
emulation.
Note that this didn't use to be a problem because QEMU was buggy and
only defined 128 interrupts until recently.
[ Sending this as an RFC, because I haven't convinced myself that
this is even the right short-term fix. On a longer-term we probably
need a way for QEMU to tell the kernel how many IRQs it needs for a
particular implementation of a CPU and a GIC, but on a shorter term
we should at least support a real A15 configuration. Note that this
change increases the in-kernel memory consumption quite a bit,
especially due to the irq-to-lr map, which could be reversed or
turned into a hash table or list, at the sacrifice of some
performance during world-switches to search the data structure. ]
Signed-off-by: Christoffer Dall <christoffer.dall(a)linaro.org>
---
include/kvm/arm_vgic.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/kvm/arm_vgic.h b/include/kvm/arm_vgic.h
index 343744e..7e2d158 100644
--- a/include/kvm/arm_vgic.h
+++ b/include/kvm/arm_vgic.h
@@ -26,7 +26,7 @@
#include <linux/types.h>
#include <linux/irqchip/arm-gic.h>
-#define VGIC_NR_IRQS 128
+#define VGIC_NR_IRQS 256
#define VGIC_NR_SGIS 16
#define VGIC_NR_PPIS 16
#define VGIC_NR_PRIVATE_IRQS (VGIC_NR_SGIS + VGIC_NR_PPIS)
--
1.7.10.4
For bytemaps each IRQ field is 1 byte wide, so we pack 4 irq fields in
one word and since there are 32 private (per cpu) irqs, we have 8
private u32 fields on the vgic_bytemap struct. We shift the offset from
the base of the register group right by 2, giving us the word index
instead of the field index. But then there are 8 private words, not 4,
which is also why we subtract 8 words from the offset of the shared
words.
Signed-off-by: Christoffer Dall <christoffer.dall(a)linaro.org>
---
virt/kvm/arm/vgic.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/virt/kvm/arm/vgic.c b/virt/kvm/arm/vgic.c
index 17c5ac7..96d7aa4 100644
--- a/virt/kvm/arm/vgic.c
+++ b/virt/kvm/arm/vgic.c
@@ -149,7 +149,7 @@ static u32 *vgic_bytemap_get_reg(struct vgic_bytemap *x, int cpuid, u32 offset)
{
offset >>= 2;
BUG_ON(offset > (VGIC_NR_IRQS / 4));
- if (offset < 4)
+ if (offset < 8)
return x->percpu[cpuid] + offset;
else
return x->shared + offset - 8;
--
1.7.10.4
This patch set contains userland changes necessary for out-of-the-box
support of persistent events. These patches are follow on patches of
the kernel patches I sent out today:
[PATCH 00/16] perf, persistent: Kernel updates for perf tool integration
Persistent events are always enabled kernel events. Buffers are mapped
readonly and multiple users are allowed. The persistent event flag of
the event attribute must be set to specify such an event.
The following changes to perf tools are necessary to support
persistent events. A way is needed to specify sysfs entries to set
event flags. For this a new syntax 'attr<num>' was added to the event
parser, see patch #3. We also need to change perf tools to mmap
persistent event buffers readonly.
All patches can be found here:
git://git.kernel.org/pub/scm/linux/kernel/git/rric/oprofile.git persistent-v3
-Robert
Robert Richter (4):
perf tools: Rename flex conditions to avoid name conflicts
perf tools: Modify event parser to update event attribute by index
perf tools: Add attr<num> syntax to event parser
perf tools: Retry mapping buffers readonly on EACCES
tools/perf/builtin-record.c | 11 +++++---
tools/perf/builtin-top.c | 8 ++++--
tools/perf/perf.h | 1 +
tools/perf/tests/parse-events.c | 12 ++++++---
tools/perf/util/parse-events.c | 59 +++++++++++++++++++----------------------
tools/perf/util/parse-events.h | 12 ++++-----
tools/perf/util/parse-events.l | 56 +++++++++++++++++++++++---------------
tools/perf/util/parse-events.y | 24 ++++++++++-------
tools/perf/util/pmu.c | 32 +++++-----------------
tools/perf/util/pmu.h | 9 ++-----
tools/perf/util/pmu.l | 1 +
tools/perf/util/pmu.y | 18 ++++++++++---
12 files changed, 129 insertions(+), 114 deletions(-)
--
1.8.3.2
This patch set implements the necessary kernel changes for persistent
events.
Persistent events run standalone in the system without the need of a
controlling process that holds an event's file descriptor. The events
are always enabled and collect data samples in a ring buffer.
Processes may connect to existing persistent events using the
perf_event_open() syscall. For this the syscall must be configured
using the new PERF_TYPE_PERSISTENT event type and a unique event
identifier specified in attr.config. The id is propagated in sysfs or
using ioctl (see below).
Persistent event buffers may be accessed with mmap() in the same way
as for any other event. Since the buffers may be used by multiple
processes at the same time, there is only read-only access to them.
Currently there is only support for per-cpu events, thus root access
is needed too.
Persistent events are visible in sysfs. They are added or removed
dynamically. With the information in sysfs userland knows about how to
setup the perf_event attribute of a persistent event. Since a
persistent event always has the persistent flag set, a way is needed
to express this in sysfs. A new syntax is used for this. With
'attr<num>:<mask>' any bit in the attribute structure may be set in a
similar way as using 'config<num>', but <num> is an index that points
to the u64 value to change within the attribute.
For persistent events the persistent flag (bit 23 of flag field in
struct perf_event_attr) needs to be set which is expressed in sysfs
with "attr5:23". E.g. the mce_record event is described in sysfs as
follows:
/sys/bus/event_source/devices/persistent/events/mce_record:persistent,config=106
/sys/bus/event_source/devices/persistent/format/persistent:attr5:23
Note that perf tools need to support the 'attr<num>' syntax that is
added in a separate patch set. With it we are able to run perf tool
commands to read persistent events, e.g.:
# perf record -e persistent/mce_record/ sleep 10
# perf top -e persistent/mce_record/
In general the new syntax is flexible to describe with sysfs any event
to be setup by perf tools.
There are ioctl functions to control persistent events that can be
used to detach or attach an event to or from a process. The
PERF_EVENT_IOC_DETACH ioctl call makes an event persistent. The
perf_event_open() syscall can be used to re-open the event by any
process. The PERF_EVENT_IOC_ATTACH ioctl attaches the event again so
that it is removed after closing the event's fd.
The patches base on the originally work from Borislav Petkov.
This version 3 of the patch set is a complete rework of the code.
There are the following major changes:
* new event type PERF_TYPE_PERSISTENT introduced,
* support for all type of events,
* unique event ids,
* improvements in reference counting and locking,
* ioctl functions are added to control persistency,
* the sysfs implementation now uses variable list size.
This should address most issues discussed during last review of
version 2. The following is unresolved yet and can be added later on
top of this patches, if necessary:
* support for per-task events (also allowing non-root access),
* creation of persistent events for disabled cpus,
* make event persistent with already open (mmap'ed) buffers,
* make event persistent while creating it.
First patches contain some rework of the perf mmap code to reuse it
for persistent events.
Also note that patch 12 (ioctl functions to control persistency) is
RFC and untested. A perf tools implementation for this is missing and
some ideas are needed how this could be integrated, esp. in something
like perf trace or so.
All patches can be found here:
git://git.kernel.org/pub/scm/linux/kernel/git/rric/oprofile.git persistent-v3
Note: I will resent the perf tools patch necessary to use persistent
events.
-Robert
Borislav Petkov (1):
mce, x86: Enable persistent events
Robert Richter (11):
perf, mmap: Factor out ring_buffer_detach_all()
perf, mmap: Factor out try_get_event()/put_event()
perf, mmap: Factor out perf_alloc/free_rb()
perf, mmap: Factor out perf_get_fd()
perf: Add persistent events
perf, persistent: Implementing a persistent pmu
perf, persistent: Exposing persistent events using sysfs
perf, persistent: Use unique event ids
perf, persistent: Implement reference counter for events
perf, persistent: Dynamically resize list of sysfs entries
[RFC] perf, persistent: ioctl functions to control persistency
.../testing/sysfs-bus-event_source-devices-format | 43 +-
arch/x86/kernel/cpu/mcheck/mce.c | 19 +
include/linux/perf_event.h | 12 +-
include/uapi/linux/perf_event.h | 6 +-
kernel/events/Makefile | 2 +-
kernel/events/core.c | 210 +++++---
kernel/events/internal.h | 20 +
kernel/events/persistent.c | 563 +++++++++++++++++++++
8 files changed, 779 insertions(+), 96 deletions(-)
create mode 100644 kernel/events/persistent.c
--
1.8.3.2
This patchset does the following 3 things:
1) Fixes the RTC DT node name for Exynos5250 SoC
2) Update the "status" property of RTC DT node for Exynos5250 SoC
3) Adds RTC DT node to Exynos5420 SoC
changes since v4:
- removed "status" property of RTC DT node from exynos5250 board dts files
changes since v3:
- split the 5250 related modifications into 2 separate patch as
suggested by Tomasz Figa <t.figa(a)samsung.com>
changes since v2:
- split the 5250 related modifications into a separate patch.
- placed the RTC node as per the alphabetical order in the DTS file as
suggested by Kukjin Kim <kgene(a)kernel.org>.
changes since v1:
- made DT node status as "okay" in the dtsi file itself.
Vikas Sajjan (3):
ARM: dts: Fix the RTC DT node name for Exynos5250 SoC
ARM: dts: Update the "status" property of RTC DT node for Exynos5250
SoC
ARM: dts: Add RTC DT node to Exynos5420 SoC
arch/arm/boot/dts/exynos5.dtsi | 2 +-
arch/arm/boot/dts/exynos5250-arndale.dts | 4 ----
arch/arm/boot/dts/exynos5250-snow.dts | 4 ----
arch/arm/boot/dts/exynos5250.dtsi | 3 ++-
arch/arm/boot/dts/exynos5420.dtsi | 6 ++++++
5 files changed, 9 insertions(+), 10 deletions(-)
--
1.7.9.5
Hi all,
This patch set introduces a buffer synchronization framework based
on DMA BUF[1] and based on ww-mutexes[2] for lock mechanism, and
has been rebased on linux-3.11-rc6.
The purpose of this framework is to provide not only buffer access
control to CPU and CPU, and CPU and DMA, and DMA and DMA but also
easy-to-use interfaces for device drivers and user application.
In addtion, this patch set suggests a way for enhancing performance.
Changelog v7:
Fix things pointed out by Konrad Rzeszutek Wilk,
- Use EXPORT_SYMBOL_GPL instead of EXPORT_SYMBOL.
- Make sure to unlock and unreference all dmabuf objects
when dmabuf_sync_fini() is called.
- Add more comments.
- Code cleanups.
Changelog v6:
- Fix sync lock to multiple reads.
- Add select system call support.
. Wake up poll_wait when a dmabuf is unlocked.
- Remove unnecessary the use of mutex lock.
- Add private backend ops callbacks.
. This ops has one callback for device drivers to clean up their
sync object resource when the sync object is freed. For this,
device drivers should implement the free callback properly.
- Update document file.
Changelog v5:
- Rmove a dependence on reservation_object: the reservation_object is used
to hook up to ttm and dma-buf for easy sharing of reservations across
devices. However, the dmabuf sync can be used for all dma devices; v4l2
and drm based drivers, so doesn't need the reservation_object anymore.
With regared to this, it adds 'void *sync' to dma_buf structure.
- All patches are rebased on mainline, Linux v3.10.
Changelog v4:
- Add user side interface for buffer synchronization mechanism and update
descriptions related to the user side interface.
Changelog v3:
- remove cache operation relevant codes and update document file.
Changelog v2:
- use atomic_add_unless to avoid potential bug.
- add a macro for checking valid access type.
- code clean.
For generic user mode interface, we have used fcntl and select system
call[3]. As you know, user application sees a buffer object as a dma-buf
file descriptor. So fcntl() call with the file descriptor means to lock
some buffer region being managed by the dma-buf object. And select() call
means to wait for the completion of CPU or DMA access to the dma-buf
without locking. For more detail, you can refer to the dma-buf-sync.txt
in Documentation/
There are some cases we should use this buffer synchronization framework.
One of which is to primarily enhance GPU rendering performance on Tizen
platform in case of 3d app with compositing mode that 3d app draws
something in off-screen buffer, and Web app.
In case of 3d app with compositing mode which is not a full screen mode,
the app calls glFlush to submit 3d commands to GPU driver instead of
glFinish for more performance. The reason we call glFlush is that glFinish
blocks caller's task until the execution of the 2d commands is completed.
Thus, that makes GPU and CPU more idle. As result, 3d rendering performance
with glFinish is quite lower than glFlush. However, the use of glFlush has
one issue that the a buffer shared with GPU could be broken when CPU
accesses the buffer at once after glFlush because CPU cannot be aware of
the completion of GPU access to the buffer. Of course, the app can be aware
of that time using eglWaitGL but this function is valid only in case of the
same process.
The below summarizes how app's window is displayed on Tizen platform:
1. X client requests a window buffer to Xorg.
2. X client draws something in the window buffer using CPU.
3. X client requests SWAP to Xorg.
4. Xorg notifies a damage event to Composite Manager.
5. Composite Manager gets the window buffer (front buffer) through
DRI2GetBuffers.
6. Composite Manager composes the window buffer and its own back buffer
using GPU. At this time, eglSwapBuffers is called: internally, 3d
commands are flushed to gpu driver.
7. Composite Manager requests SWAP to Xorg.
8. Xorg performs drm page flip. At this time, the window buffer is
displayed on screen.
Web app based on HTML5 also has the same issue. Web browser and its web app
are different process. The web app draws something in its own pixmap buffer,
and then the web browser gets a window buffer from Xorg, and then composites
the pixmap buffer with the window buffer. And finally, page flip.
Thus, in such cases, a shared buffer could be broken as one process draws
something in pixmap buffer using CPU, when other process composites the
pixmap buffer with window buffer using GPU without any locking mechanism.
That is why we need user land locking interface, fcntl system call.
And last one is a deferred page flip issue. This issue is that a window
buffer rendered can be displayed on screen in about 32ms in worst case:
assume that the gpu rendering is completed within 16ms.
That can be incurred when compositing a pixmap buffer with a window buffer
using GPU and when vsync is just started. At this time, Xorg waits for
a vblank event to get a window buffer so 3d rendering will be delayed
up to about 16ms. As a result, the window buffer would be displayed in
about two vsyncs (about 32ms) and in turn, that would show slow
responsiveness.
For this, we could enhance the responsiveness with locking
mechanism: skipping one vblank wait. I guess in the similar reason,
Android, Chrome OS, and other platforms are using their own locking
mechanisms; Android sync driver, KDS, and DMA fence.
The below shows the deferred page flip issue in worst case,
|------------ <- vsync signal
|<------ DRI2GetBuffers
|
|
|
|------------ <- vsync signal
|<------ Request gpu rendering
time |
|
|<------ Request page flip (deferred)
|------------ <- vsync signal
|<------ Displayed on screen
|
|
|
|------------ <- vsync signal
Thanks,
Inki Dae
References:
[1] http://lwn.net/Articles/470339/
[2] https://patchwork.kernel.org/patch/2625361/
[3] http://linux.die.net/man/2/fcntl
Inki Dae (2):
dmabuf-sync: Add a buffer synchronization framework
dma-buf: Add user interfaces for dmabuf sync support
Documentation/dma-buf-sync.txt | 286 ++++++++++++++++
drivers/base/Kconfig | 7 +
drivers/base/Makefile | 1 +
drivers/base/dma-buf.c | 85 +++++
drivers/base/dmabuf-sync.c | 706 ++++++++++++++++++++++++++++++++++++++++
include/linux/dma-buf.h | 16 +
include/linux/dmabuf-sync.h | 236 ++++++++++++++
7 files changed, 1337 insertions(+), 0 deletions(-)
create mode 100644 Documentation/dma-buf-sync.txt
create mode 100644 drivers/base/dmabuf-sync.c
create mode 100644 include/linux/dmabuf-sync.h
--
1.7.5.4
Many CPUFreq drivers for SMP system (where all cores share same clock lines), do
similar stuff in their ->init() part.
This patch creates a generic routine in cpufreq core which can be used by these
so that we can remove some redundant code. And later part of patchset makes
other drivers use this infrastructure.
Many drivers which weren't setting policy->cpus haven't been updated as they
might have separate clocks for CPUs and setting all CPUs in policy->cpus may
corrupt them..
This is Sixth part of my cleanup work for CPUFreq, first five are (And
obviously its rebased over them):
1: cpufreq: Introduce cpufreq_table_validate_and_show()
https://lkml.org/lkml/2013/8/8/263
2: cpufreq: define generic routines for cpufreq drivers
https://lkml.org/lkml/2013/8/10/48
3. CPUFreq: Implement light weight ->target(): for 3.13
https://lkml.org/lkml/2013/8/13/349
4. CPUFreq: set policy->cur in cpufreq core instead of drivers
https://lkml.org/lkml/2013/8/14/288
5. CPUFreq: Move freq change notifications out of drivers
https://lkml.org/lkml/2013/8/15/506
All these are pushed here:
https://git.linaro.org/gitweb?p=people/vireshk/linux.git;a=shortlog;h=refs/…
Viresh Kumar (14):
cpufreq: create cpufreq_generic_init() routine
cpufreq: cpu0: use cpufreq_generic_init() routine
cpufreq: dbx500: use cpufreq_generic_init() routine
cpufreq: exynos: use cpufreq_generic_init() routine
cpufreq: imx6q: use cpufreq_generic_init() routine
cpufreq: kirkwood: use cpufreq_generic_init() routine
cpufreq: maple: use cpufreq_generic_init() routine
cpufreq: pasemi: use cpufreq_generic_init() routine
cpufreq: pmac64: use cpufreq_generic_init() routine
cpufreq: s3c: use cpufreq_generic_init() routine
cpufreq: s5pv210: use cpufreq_generic_init() routine
cpufreq: sa11x0: use cpufreq_generic_init() routine
cpufreq: spear: use cpufreq_generic_init() routine
cpufreq: tegra: use cpufreq_generic_init() routine
drivers/cpufreq/cpufreq-cpu0.c | 19 +------------------
drivers/cpufreq/cpufreq.c | 31 +++++++++++++++++++++++++++++++
drivers/cpufreq/dbx500-cpufreq.c | 21 +--------------------
drivers/cpufreq/exynos-cpufreq.c | 7 +------
drivers/cpufreq/exynos5440-cpufreq.c | 14 ++------------
drivers/cpufreq/imx6q-cpufreq.c | 13 +------------
drivers/cpufreq/kirkwood-cpufreq.c | 5 +----
drivers/cpufreq/maple-cpufreq.c | 9 +--------
drivers/cpufreq/pasemi-cpufreq.c | 9 +--------
drivers/cpufreq/pmac64-cpufreq.c | 9 +--------
drivers/cpufreq/s3c2416-cpufreq.c | 6 ++----
drivers/cpufreq/s3c24xx-cpufreq.c | 13 +------------
drivers/cpufreq/s3c64xx-cpufreq.c | 5 ++---
drivers/cpufreq/s5pv210-cpufreq.c | 4 +---
drivers/cpufreq/sa1100-cpufreq.c | 6 +-----
drivers/cpufreq/sa1110-cpufreq.c | 6 +-----
drivers/cpufreq/spear-cpufreq.c | 14 ++------------
drivers/cpufreq/tegra-cpufreq.c | 14 +++++++++-----
include/linux/cpufreq.h | 3 +++
19 files changed, 63 insertions(+), 145 deletions(-)
--
1.7.12.rc2.18.g61b472e
vexpress_defconfig is known broken on some use-cases. This serie of
patches allow to boot test Versatile Express using a regular filesystem
on SD card.
Fathi Boudra (3):
ARM: vexpress_defconfig: Enable and automount devtmpfs filesystem
ARM: vexpress_defconfig: Enable voltage regulator support
ARM: vexpress_defconfig: Enable ext4 filesystem
arch/arm/configs/vexpress_defconfig | 5 +++++
1 file changed, 5 insertions(+)
--
1.8.1.2
Tegra's cpufreq driver was maintaining requested target frequencies in an array:
target_cpu_speed. And then finally setting the highest requested freq in the
core. This was probably done because both cores share clock line and logically
we want to set both cores to the max frequency requested..
But this wasn't required to be done in individual CPUFreq drivers, its already
taken care of by CPUFreq governors. They evaluate load for all CPUs and finally
call target only for the frequency corresponding to max load.
So, get rid of this stuff from Tegra's cpufreq driver.
Signed-off-by: Viresh Kumar <viresh.kumar(a)linaro.org>
---
Hi Stephen,
Its only build tested and depends on lots of stuff that I have already sent for
cpufreq core and its drivers. All of that is pushed here:
https://git.linaro.org/gitweb?p=people/vireshk/linux.git;a=shortlog;h=refs/…
And only Tegra+cpufreq-core patches are pushed here (only 13 patches):
https://git.linaro.org/gitweb?p=people/vireshk/linux.git;a=shortlog;h=refs/…
You can probably try cpufreq-next-tegra branch for testing on some real
hardware.
drivers/cpufreq/tegra-cpufreq.c | 35 ++++++-----------------------------
1 file changed, 6 insertions(+), 29 deletions(-)
diff --git a/drivers/cpufreq/tegra-cpufreq.c b/drivers/cpufreq/tegra-cpufreq.c
index b376b67..3f25ab6 100644
--- a/drivers/cpufreq/tegra-cpufreq.c
+++ b/drivers/cpufreq/tegra-cpufreq.c
@@ -47,7 +47,6 @@ static struct clk *pll_x_clk;
static struct clk *pll_p_clk;
static struct clk *emc_clk;
-static unsigned long target_cpu_speed[NUM_CPUS];
static DEFINE_MUTEX(tegra_cpu_lock);
static bool is_suspended;
@@ -103,9 +102,6 @@ static int tegra_update_cpu_speed(struct cpufreq_policy *policy,
{
int ret = 0;
- if (tegra_getspeed(0) == rate)
- return ret;
-
/*
* Vote on memory bus frequency based on cpu frequency
* This sets the minimum frequency, display or avp may request higher
@@ -125,35 +121,16 @@ static int tegra_update_cpu_speed(struct cpufreq_policy *policy,
return ret;
}
-static unsigned long tegra_cpu_highest_speed(void)
-{
- unsigned long rate = 0;
- int i;
-
- for_each_online_cpu(i)
- rate = max(rate, target_cpu_speed[i]);
- return rate;
-}
-
static int tegra_target(struct cpufreq_policy *policy, unsigned int index)
{
- unsigned int freq;
- int ret = 0;
+ int ret = -EBUSY;
mutex_lock(&tegra_cpu_lock);
- if (is_suspended) {
- ret = -EBUSY;
- goto out;
- }
-
- freq = freq_table[index].frequency;
+ if (!is_suspended)
+ ret = tegra_update_cpu_speed(policy,
+ freq_table[index].frequency);
- target_cpu_speed[policy->cpu] = freq;
-
- ret = tegra_update_cpu_speed(policy, tegra_cpu_highest_speed());
-
-out:
mutex_unlock(&tegra_cpu_lock);
return ret;
}
@@ -167,7 +144,8 @@ static int tegra_pm_notify(struct notifier_block *nb, unsigned long event,
is_suspended = true;
pr_info("Tegra cpufreq suspend: setting frequency to %d kHz\n",
freq_table[0].frequency);
- tegra_update_cpu_speed(policy, freq_table[0].frequency);
+ if (tegra_getspeed(0) != freq_table[0].frequency)
+ tegra_update_cpu_speed(policy, freq_table[0].frequency);
cpufreq_cpu_put(policy);
} else if (event == PM_POST_SUSPEND) {
is_suspended = false;
@@ -190,7 +168,6 @@ static int tegra_cpu_init(struct cpufreq_policy *policy)
clk_prepare_enable(cpu_clk);
cpufreq_table_validate_and_show(policy, freq_table);
- target_cpu_speed[policy->cpu] = tegra_getspeed(policy->cpu);
/* FIXME: what's the actual transition time? */
policy->cpuinfo.transition_latency = 300 * 1000;
--
1.7.12.rc2.18.g61b472e
Hi all,
This patch set introduces a buffer synchronization framework based
on DMA BUF[1] and based on ww-mutexes[2] for lock mechanism, and
may be final RFC.
The purpose of this framework is to provide not only buffer access
control to CPU and CPU, and CPU and DMA, and DMA and DMA but also
easy-to-use interfaces for device drivers and user application.
In addtion, this patch set suggests a way for enhancing performance.
For generic user mode interface, we have used fcntl and select system
call[3]. As you know, user application sees a buffer object as a dma-buf
file descriptor. So fcntl() call with the file descriptor means to lock
some buffer region being managed by the dma-buf object. And select() call
means to wait for the completion of CPU or DMA access to the dma-buf
without locking. For more detail, you can refer to the dma-buf-sync.txt
in Documentation/
There are some cases we should use this buffer synchronization framework.
One of which is to primarily enhance GPU rendering performance on Tizen
platform in case of 3d app with compositing mode that 3d app draws
something in off-screen buffer, and Web app.
In case of 3d app with compositing mode which is not a full screen mode,
the app calls glFlush to submit 3d commands to GPU driver instead of
glFinish for more performance. The reason we call glFlush is that glFinish
blocks caller's task until the execution of the 2d commands is completed.
Thus, that makes GPU and CPU more idle. As result, 3d rendering performance
with glFinish is quite lower than glFlush. However, the use of glFlush has
one issue that the a buffer shared with GPU could be broken when CPU
accesses the buffer at once after glFlush because CPU cannot be aware of
the completion of GPU access to the buffer. Of course, the app can be aware
of that time using eglWaitGL but this function is valid only in case of the
same process.
In case of Tizen, there are some applications that one process draws
something in its own off-screen buffer (pixmap buffer) using CPU, and other
process gets a off-screen buffer (window buffer) from Xorg using
DRI2GetBuffers, and then composites the pixmap buffer with the window buffer
using GPU, and finally page flip.
Web app based on HTML5 also has the same issue. Web browser and its web app
are different process. The web app draws something in its own pixmap buffer,
and then the web browser gets a window buffer from Xorg, and then composites
the pixmap buffer with the window buffer. And finally, page flip.
Thus, in such cases, a shared buffer could be broken as one process draws
something in pixmap buffer using CPU, when other process composites the
pixmap buffer with window buffer using GPU without any locking mechanism.
That is why we need user land locking interface, fcntl system call.
And last one is a deferred page flip issue. This issue is that a window
buffer rendered can be displayed on screen in about 32ms in worst case:
assume that the gpu rendering is completed within 16ms.
That can be incurred when compositing a pixmap buffer with a window buffer
using GPU and when vsync is just started. At this time, Xorg waits for
a vblank event to get a window buffer so 3d rendering will be delayed
up to about 16ms. As a result, the window buffer would be displayed in
about two vsyncs (about 32ms) and in turn, that would show slow
responsiveness.
For this, we could enhance the responsiveness with locking
mechanism: skipping one vblank wait. I guess in the similar reason,
Android, Chrome OS, and other platforms are using their own locking
mechanisms; Android sync driver, KDS, and DMA fence.
The below shows the deferred page flip issue in worst case,
|------------ <- vsync signal
|<------ DRI2GetBuffers
|
|
|
|------------ <- vsync signal
|<------ Request gpu rendering
time |
|
|<------ Request page flip (deferred)
|------------ <- vsync signal
|<------ Displayed on screen
|
|
|
|------------ <- vsync signal
Thanks,
Inki Dae
References:
[1] http://lwn.net/Articles/470339/
[2] https://patchwork.kernel.org/patch/2625361/
[3] http://linux.die.net/man/2/fcntl
Inki Dae (2):
[RFC PATCH v6] dmabuf-sync: Add a buffer synchronization framework
[RFC PATCH v2] dma-buf: Add user interfaces for dmabuf sync support.
Documentation/dma-buf-sync.txt | 285 +++++++++++++++++
drivers/base/Kconfig | 7 +
drivers/base/Makefile | 1 +
drivers/base/dma-buf.c | 85 +++++
drivers/base/dmabuf-sync.c | 678 ++++++++++++++++++++++++++++++++++++++++
include/linux/dma-buf.h | 16 +
include/linux/dmabuf-sync.h | 191 +++++++++++
7 files changed, 1263 insertions(+), 0 deletions(-)
create mode 100644 Documentation/dma-buf-sync.txt
create mode 100644 drivers/base/dmabuf-sync.c
create mode 100644 include/linux/dmabuf-sync.h
--
1.7.5.4
The comment for __acpi_map_table() is obvious wrong. In fact, after
commit 1c14fa49 (x86: use early_ioremap in __acpi_map_table), the
comment became stale, so remove it and add a new one.
Signed-off-by: Hanjun Guo <hanjun.guo(a)linaro.org>
---
arch/x86/kernel/acpi/boot.c | 12 ++----------
1 file changed, 2 insertions(+), 10 deletions(-)
diff --git a/arch/x86/kernel/acpi/boot.c b/arch/x86/kernel/acpi/boot.c
index 2627a81..665f857 100644
--- a/arch/x86/kernel/acpi/boot.c
+++ b/arch/x86/kernel/acpi/boot.c
@@ -141,16 +141,8 @@ static u32 irq_to_gsi(int irq)
}
/*
- * Temporarily use the virtual area starting from FIX_IO_APIC_BASE_END,
- * to map the target physical address. The problem is that set_fixmap()
- * provides a single page, and it is possible that the page is not
- * sufficient.
- * By using this area, we can map up to MAX_IO_APICS pages temporarily,
- * i.e. until the next __va_range() call.
- *
- * Important Safety Note: The fixed I/O APIC page numbers are *subtracted*
- * from the fixed base. That's why we start at FIX_IO_APIC_BASE_END and
- * count idx down while incrementing the phys address.
+ * __acpi_map_table() will be called before the memory allocation
+ * is ready, so call early_ioremap() to map tables.
*/
char *__init __acpi_map_table(unsigned long phys, unsigned long size)
{
--
1.7.9.5
Hi Rafael,
You recently did this:
commit 878f6e074e9a7784a6e351512eace4ccb3542eef
Author: Rafael J. Wysocki <rafael.j.wysocki(a)intel.com>
Date: Sun Aug 18 15:35:59 2013 +0200
Revert "cpufreq: Use cpufreq_policy_list for iterating over policies"
Revert commit eb60852 (cpufreq: Use cpufreq_policy_list for iterating
over policies), because it breaks system suspend/resume on multiple
machines.
It either causes resume to block indefinitely or causes the BUG_ON()
in lock_policy_rwsem_##mode() to trigger on sysfs accesses to cpufreq
attributes.
------x------------x---------------
This patchset gets the reverted patch back along with few supporting patches.
Cause of the initial problem you observed was this:
- At suspend all CPUs are removed leaving boot cpu. At this time policies aren't
freed and also aren't removed from cpufreq_policy_list. And per-cpu variable
cpufreq_cpu_data is marked as NULL.
- At resume CPUs other than boot cpu called __cpufreq_add_dev(). The tricky
change that was introduced by my patch was: We iterate over list of policies
instead of CPUs, where we used to get policy structure associated with
CPUs using per-cpu variable. Which used to be NULL for first CPU of a policy
that turned up. For the first cpu we don't want to call
cpufreq_add_policy_cpu() but want __cpufreq_add_add() to continue.
When we called cpufreq_add_policy_cpu() it tried to stop the governor (which
was already stopped) and hence errors leading into unstable state.
This patchset fixes these issues and is tested with suspend-resume over my
thinkpad with ubuntu. Apart from minor cleanups it removes policy from
cpufreq_policy_list in case of suspend/resume as well and hence we will never
call cpufreq_add_policy_cpu() for first cpu of a policy.
--
viresh
Viresh Kumar (5):
cpufreq: align closing brace '}' of an if block
cpufreq: remove policy from cpufreq_policy_list in system suspend
cpufreq: remove unnecessary check in __cpufreq_governor()
cpufreq: remove cpufreq_policy_cpu per-cpu variable
cpufreq: Use cpufreq_policy_list for iterating over policies
drivers/cpufreq/cpufreq.c | 77 +++++++++++++++--------------------------------
1 file changed, 24 insertions(+), 53 deletions(-)
--
1.7.12.rc2.18.g61b472e
Hi Mark
I have some big.LITTLE MP updates for LSK, these are based on your topic
v3.10/topic/big.LITTLE. Can you please pull these for this month's LSK
release?
Thanks
Tixy
The following changes since commit a0e1bccdf9f1c4d68ea024e4254dbbd1eff96a4a:
Merge branches 'master-arm-multi_pmu_v2', 'master-config-fragments', 'master-hw-bkpt-fix', 'master-misc-patches' and 'master-task-placement-v2-updates' into big-LITTLE-MP-master-v19 (2013-07-18 11:49:27 +0100)
are available in the git repository at:
git://git.linaro.org/arm/big.LITTLE/mp.git master
for you to fetch changes up to 18e3c3d2cc1346cb7cc2e3fd777b2c6f4fbb6135:
HMP: Update migration timer when we fork-migrate (2013-08-19 15:41:37 +0100)
----------------------------------------------------------------
Chris Redpath (8):
HMP: select 'best' task for migration rather than 'current'
sched: track per-rq 'last migration time'
HMP: Modify the runqueue stats to add a new child stat
HMP: Explicitly implement all-load-is-max-load policy for HMP targets
sched: HMP change nr_running offload metric
HMP: Implement idle pull for HMP
HMP: Access runqueue task clocks directly.
HMP: Update migration timer when we fork-migrate
Morten Rasmussen (1):
sched: HMP fix traversing the rb-tree from the curr pointer
kernel/sched/fair.c | 373 +++++++++++++++++++++++++++++++++++++++++++++------
1 file changed, 330 insertions(+), 43 deletions(-)
Hi Rafael,
This is V2 of the patch series which was posted here earlier:
http://www.gossamer-threads.com/lists/linux/kernel/1759514
This patchset tries to fix & cleanup many existing cpufreq core issues. First
four patches tries to cleanup basic problems in cpufreq core. Its first patch
was earlier sent separately but now is part of this series.
Fifth patch was also sent earlier as reply to your patches and was reviewed by
Srivatsa. Sixth patch was picked from Lukasz's patchset on introducing software
"boost" feature in core. It will be used by this patchset.
And 7-10 are are the most significant part of this set. They try to make many
things simple and robust.
Last patch in the series is new and wasn't part of V1.
This is rebased of your bleeding-edge branch + two patches from you:
18a6b03 cpufreq: Avoid double kobject_put() for the same kobject in error code path
d0cde63 cpufreq: Do not hold driver module references for additional policy CPUs
abe513f Merge branch 'acpi-sleep-next' into linux-next
They are also pushed in my cpufreq-next branch.
They are tested fairly well on ARM Vexpress TC2 board (big LITTLE).
Lukasz Majewski (1):
cpufreq: Store cpufreq policies in a list
Viresh Kumar (10):
cpufreq: Cleanup header files included in core
cpufreq: Re-arrange declarations in cpufreq.h
cpufreq: Give consistent names for struct cpufreq_policy *
cpufreq: Use sizeof(*ptr) form for finding size of a struct
cpufreq: Pass policy to cpufreq_add_policy_cpu()
cpufreq: Use cpufreq_policy_list for iterating over policies
cpufreq: Fix broken usage of governor->owner's refcount
cpufreq: Don't use cpufreq_driver->owner's refcount to protect
critical sections
cpufreq: Remove struct cpufreq_driver's owner field
cpufreq: improve error checking on return values of
__cpufreq_governor()
Documentation/cpu-freq/cpu-drivers.txt | 2 -
drivers/cpufreq/acpi-cpufreq.c | 5 +-
drivers/cpufreq/at32ap-cpufreq.c | 1 -
drivers/cpufreq/blackfin-cpufreq.c | 1 -
drivers/cpufreq/cpufreq-nforce2.c | 1 -
drivers/cpufreq/cpufreq.c | 426 ++++++++++++++++-----------------
drivers/cpufreq/cpufreq_conservative.c | 14 +-
drivers/cpufreq/cpufreq_governor.c | 6 -
drivers/cpufreq/cpufreq_governor.h | 7 +-
drivers/cpufreq/cpufreq_ondemand.c | 24 +-
drivers/cpufreq/cpufreq_performance.c | 3 +-
drivers/cpufreq/cpufreq_powersave.c | 3 +-
drivers/cpufreq/cpufreq_stats.c | 23 +-
drivers/cpufreq/cris-artpec3-cpufreq.c | 1 -
drivers/cpufreq/cris-etraxfs-cpufreq.c | 1 -
drivers/cpufreq/e_powersaver.c | 5 +-
drivers/cpufreq/elanfreq.c | 1 -
drivers/cpufreq/exynos-cpufreq.c | 2 +-
drivers/cpufreq/freq_table.c | 4 +-
drivers/cpufreq/gx-suspmod.c | 3 +-
drivers/cpufreq/ia64-acpi-cpufreq.c | 5 +-
drivers/cpufreq/intel_pstate.c | 1 -
drivers/cpufreq/kirkwood-cpufreq.c | 1 -
drivers/cpufreq/longhaul.c | 1 -
drivers/cpufreq/longrun.c | 1 -
drivers/cpufreq/loongson2_cpufreq.c | 1 -
drivers/cpufreq/maple-cpufreq.c | 1 -
drivers/cpufreq/p4-clockmod.c | 1 -
drivers/cpufreq/pasemi-cpufreq.c | 1 -
drivers/cpufreq/pcc-cpufreq.c | 1 -
drivers/cpufreq/pmac32-cpufreq.c | 1 -
drivers/cpufreq/pmac64-cpufreq.c | 6 +-
drivers/cpufreq/powernow-k6.c | 1 -
drivers/cpufreq/powernow-k7.c | 14 +-
drivers/cpufreq/powernow-k8.c | 7 +-
drivers/cpufreq/ppc-corenet-cpufreq.c | 1 -
drivers/cpufreq/ppc_cbe_cpufreq.c | 1 -
drivers/cpufreq/s3c2416-cpufreq.c | 1 -
drivers/cpufreq/s3c24xx-cpufreq.c | 6 +-
drivers/cpufreq/s3c64xx-cpufreq.c | 1 -
drivers/cpufreq/sc520_freq.c | 1 -
drivers/cpufreq/sh-cpufreq.c | 1 -
drivers/cpufreq/sparc-us2e-cpufreq.c | 6 +-
drivers/cpufreq/sparc-us3-cpufreq.c | 6 +-
drivers/cpufreq/speedstep-centrino.c | 1 -
drivers/cpufreq/speedstep-ich.c | 1 -
drivers/cpufreq/speedstep-smi.c | 1 -
include/linux/cpufreq.h | 386 ++++++++++++++---------------
48 files changed, 442 insertions(+), 547 deletions(-)
--
1.7.12.rc2.18.g61b472e
This is second version of patch that fixes rt_sig* ltp failures
in case of big endian V7 kernel. It make sigreturn_codes snippets
endian neutral. In this version of the patch problem is fixed by
using separate .S file with snippets written with regular asm
mnemonic. With such change compiler/linker take care of all needed
byteswaps in case of BE8 mode.
This approach was suggested on the following thread:
http://lists.infradead.org/pipermail/linux-arm-kernel/2013-August/191543.ht…
Changes were tested on V7 in both BE and LE modes
Changes from v1:
Use separate .S file rather than <asm/opcodes.h> instruction
byteswaping macros
Victor Kamensky (1):
ARM: signal: sigreturn_codes should be endian neutral to work in BE8
arch/arm/kernel/Makefile | 3 +-
arch/arm/kernel/signal.c | 29 +++---------------
arch/arm/kernel/sigreturn_codes.S | 64 +++++++++++++++++++++++++++++++++++++++
3 files changed, 70 insertions(+), 26 deletions(-)
create mode 100644 arch/arm/kernel/sigreturn_codes.S
--
1.8.1.4
Enable voltage regulators by default for versatile express.
This should work on all verstatile express platforms and not enabling it
prevents a defconfig'ed kernel from using the SD card controller on the
qemu emulated platform, which is unfortunate for first-time casual
users.
Cc: Peter Maydell <peter.maydell(a)linaro.org>
Cc: Jon Medhurst (Tixy) <tixy(a)linaro.org>
Signed-off-by: Christoffer Dall <christoffer.dall(a)linaro.org>
---
Changelog[v1 -> v2]:
- Only enabling CONFIG_REGULATOR is sufficient to boot qemu guests as
pointedout by Tixy.
arch/arm/configs/vexpress_defconfig | 1 +
1 file changed, 1 insertion(+)
diff --git a/arch/arm/configs/vexpress_defconfig b/arch/arm/configs/vexpress_defconfig
index f2de51f..d46c22a 100644
--- a/arch/arm/configs/vexpress_defconfig
+++ b/arch/arm/configs/vexpress_defconfig
@@ -138,3 +138,4 @@ CONFIG_DEBUG_LL=y
CONFIG_EARLY_PRINTK=y
# CONFIG_CRYPTO_ANSI_CPRNG is not set
# CONFIG_CRYPTO_HW is not set
+CONFIG_REGULATOR=y
--
1.7.10.4
The -rt patch triggers a lockdep warning for serial drivers if
tty_flip_buffer_push() is called with uart_port->lock locked. This never shows
up on UP kernels.
Release the port lock before calling tty_flip_buffer_push() and reacquire it
after the call.
Similar stuff was already done for few other drivers in the past, like:
commit 2389b272168ceec056ca1d8a870a97fa9c26e11a
Author: Thomas Gleixner <tglx(a)linutronix.de>
Date: Tue May 29 21:53:50 2007 +0100
[ARM] 4417/1: Serial: Fix AMBA drivers locking
This is neither tested nor compiled. I was working on Samsung's Arndale board
and so was required to samsung serial driver. Then thought why not others :)
Rebased over: v3.11-rc5
Cc: Bryan Huntsman <bryanh(a)codeaurora.org>
Cc: Daniel Walker <dwalker(a)fifo99.com>
Cc: David Brown <davidb(a)codeaurora.org>
Cc: Stephen Warren <swarren(a)wwwdotorg.org>
Cc: Tobias Klauser <tklauser(a)distanz.ch>
Cc: Tony Prisk <linux(a)prisktech.co.nz>
Viresh Kumar (25):
tty: serial: altera_jtag: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: altera: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: apbuart: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: ar933x: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: arc: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: bcm63xx: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: bfin_sport: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: efm32: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: icom: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: lpc32xx_hs: don't call tty_flip_buffer_push() twice
tty: serial: lpc32xx_hs: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: m32r_sio: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: mcf: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: mfd: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: mpsc: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: msm: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: netx: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: nwpserial: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: pnx8xxx: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: rp2: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: sa1100: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: samsung: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: tegra: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: sirfsoc: drop uart_port->lock before calling
tty_flip_buffer_push()
tty: serial: vt8500: drop uart_port->lock before calling
tty_flip_buffer_push()
drivers/tty/serial/altera_jtaguart.c | 2 ++
drivers/tty/serial/altera_uart.c | 2 ++
drivers/tty/serial/apbuart.c | 2 ++
drivers/tty/serial/ar933x_uart.c | 2 ++
drivers/tty/serial/arc_uart.c | 2 ++
drivers/tty/serial/bcm63xx_uart.c | 2 ++
drivers/tty/serial/bfin_sport_uart.c | 5 +++--
drivers/tty/serial/efm32-uart.c | 4 ++--
drivers/tty/serial/icom.c | 3 +++
drivers/tty/serial/lpc32xx_hs.c | 7 ++++---
drivers/tty/serial/m32r_sio.c | 3 +++
drivers/tty/serial/mcf.c | 2 ++
drivers/tty/serial/mfd.c | 14 ++++++++++----
drivers/tty/serial/mpsc.c | 11 ++++++++---
drivers/tty/serial/msm_serial.c | 5 +++++
drivers/tty/serial/netx-serial.c | 6 ++++--
drivers/tty/serial/nwpserial.c | 3 +++
drivers/tty/serial/pnx8xxx_uart.c | 3 +++
drivers/tty/serial/rp2.c | 2 ++
drivers/tty/serial/sa1100.c | 3 +++
drivers/tty/serial/samsung.c | 5 ++++-
drivers/tty/serial/serial-tegra.c | 10 ++++++++--
drivers/tty/serial/sirfsoc_uart.c | 3 +++
drivers/tty/serial/vt8500_serial.c | 2 ++
24 files changed, 84 insertions(+), 19 deletions(-)
--
1.7.12.rc2.18.g61b472e
From: Mark Brown <broonie(a)linaro.org>
Provide a common compatible string for device trees to list as a fallback
for simplicity. We don't currently have a binding document but let's not
fix that right now...
Signed-off-by: Mark Brown <broonie(a)linaro.org>
---
sound/soc/codecs/bt-sco.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/sound/soc/codecs/bt-sco.c b/sound/soc/codecs/bt-sco.c
index a081d9f..5c040ce 100644
--- a/sound/soc/codecs/bt-sco.c
+++ b/sound/soc/codecs/bt-sco.c
@@ -50,6 +50,9 @@ static struct platform_device_id bt_sco_driver_ids[] = {
{
.name = "dfbmcs320",
},
+ {
+ .name = "bt-sco",
+ },
{},
};
MODULE_DEVICE_TABLE(platform, bt_sco_driver_ids);
--
1.8.4.rc3
On 1 August 2013 20:46, Jon Medhurst (Tixy) <tixy(a)linaro.org> wrote:
> On Thu, 2013-08-01 at 17:40 +0100, Peter Maydell wrote:
>> On 1 August 2013 09:30, Ryan Harkin <ryan.harkin(a)linaro.org> wrote:
>> > The vexpress defconfig has always been broken.
>>
>> ...maybe we could fix it?
>
> It has been suggested that should be deleted as people can use the
> multiplatform defconfig (though I believe that is missing the regulator
> config for mmc as well).
>
> People have different ideas where various configs should live, boards
> specific defconfig, multiplatform defconfig or in Kconfig; and any
> particular change probably would have people arguing against it. And
> with vexpress we have the added complication thrown into the mix that
> people use it a lot with QEMU ;-)
For the kernel CI, we build all the defconfigs and boot test on
available platforms in LAVA lab.
Since vexpress_defconfig is known broken
(https://bugs.launchpad.net/linaro-ci/+bug/1212893),
what's the next step to move forward?
This patchset does the following 3 things:
1) Fixes the RTC DT node name for Exynos5250 SoC
2) Updates the status of RTC DT node of Exynos5250 SoC to "okay"
3) Adds RTC DT node to Exynos5420 SoC
changes since v3:
- split the 5250 related modifications into 2 separate patch as
suggested by Tomasz Figa <t.figa(a)samsung.com>
changes since v2:
- split the 5250 related modifications into a separate patch.
- placed the RTC node as per the alphabetical order in the DTS file as
suggested by Kukjin Kim <kgene(a)kernel.org>.
changes since v1:
- made DT node status as "okay" in the dtsi file itself.
Vikas Sajjan (3):
ARM: dts: Fix the RTC DT node name for Exynos5250 SoC
ARM: dts: Update the status of RTC DT node of Exynos5250 SoC to
"okay"
ARM: dts: Add RTC DT node to Exynos5420 SoC
arch/arm/boot/dts/exynos5.dtsi | 2 +-
arch/arm/boot/dts/exynos5250.dtsi | 3 ++-
arch/arm/boot/dts/exynos5420.dtsi | 6 ++++++
3 files changed, 9 insertions(+), 2 deletions(-)
--
1.7.9.5
Currently prototype of cpufreq_drivers target routines is:
int target(struct cpufreq_policy *policy, unsigned int target_freq,
unsigned int relation);
And most of the drivers call cpufreq_frequency_table_target() to get a valid
index of their frequency table which is closest to the target_freq. And they
don't use target_freq and relation after it.
So, it makes sense to just do this work in cpufreq core before calling
cpufreq_frequency_table_target() and simply pass index instead. But this can be
done only with drivers which expose their frequency table with cpufreq core. For
others we need to stick with the old prototype of target() until those drivers
are converted to expose frequency tables.
There are 7 drivers after this patchset which still use the heavy weight
version, i.e. target() and 44 drivers have adopted this new approach, i.e.
target_index().
Once those 7 drivers are also moved to use .target_index(), .target() will be
removed completely.
This is part 3 of my generic cpufreq cleanup stuff.. First two are posted here
and this one is rebased of them:
1: cpufreq: Introduce cpufreq_table_validate_and_show()
https://lkml.org/lkml/2013/8/8/263
2: cpufreq: define generic routines for cpufreq drivers
https://lkml.org/lkml/2013/8/10/48
All these are pushed here:
https://git.linaro.org/gitweb?p=people/vireshk/linux.git;a=shortlog;h=refs/…
V1->V2:
------
- Must be less ugly this time :)
- new interface is named as target_index() instead of target()
- old interface is kept as target() instead of target_old()
- few more drivers got converted to use this infrastructure (5)
- Documentation updates
- CONFIG_CPU_FREQ_TABLE removed completely as core depends on it now
Cc: Andrew Lunn <andrew(a)lunn.ch>
Cc: David S. Miller <davem(a)davemloft.net>
Cc: Dmitry Eremin-Solenikov <dbaryshkov(a)gmail.com>
Cc: Eric Miao <eric.y.miao(a)gmail.com>
Cc: Hans-Christian Egtvedt <egtvedt(a)samfundet.no>
Cc: Jesper Nilsson <jesper.nilsson(a)axis.com>
Cc: John Crispin <blogic(a)openwrt.org>
Cc: Kukjin Kim <kgene.kim(a)samsung.com>
Cc: Linus Walleij <linus.walleij(a)linaro.org>
Cc: linux-cris-kernel(a)axis.com
Cc: Mikael Starvik <starvik(a)axis.com>
Cc: Santosh Shilimkar <santosh.shilimkar(a)ti.com>
Cc: Sekhar Nori <nsekhar(a)ti.com>
Cc: Shawn Guo <shawn.guo(a)linaro.org>
Cc: sparclinux(a)vger.kernel.org
Cc: Stephen Warren <swarren(a)nvidia.com>
Cc: Steven Miao <realmz6(a)gmail.com>
Cc: Tony Luck <tony.luck(a)intel.com>
Viresh Kumar (35):
cpufreq: Implement light weight ->target_index() routine
cpufreq: remove CONFIG_CPU_FREQ_TABLE
cpufreq: acpi: Covert to light weight ->target_index() routine
cpufreq: arm_big_little: Covert to light weight ->target_index()
routine
cpufreq: at32ap: Covert to light weight ->target_index() routine
cpufreq: blackfin: Covert to light weight ->target_index() routine
cpufreq: cpu0: Covert to light weight ->target_index() routine
cpufreq: cris: Covert to light weight ->target_index() routine
cpufreq: davinci: Covert to light weight ->target_index() routine
cpufreq: dbx500: Covert to light weight ->target_index() routine
cpufreq: e_powersaver: Covert to light weight ->target_index()
routine
cpufreq: elanfreq: Covert to light weight ->target_index() routine
cpufreq: exynos: Covert to light weight ->target_index() routine
cpufreq: ia64: Covert to light weight ->target_index() routine
cpufreq: imx6q: Covert to light weight ->target_index() routine
cpufreq: kirkwood: Covert to light weight ->target_index() routine
cpufreq: longhaul: Covert to light weight ->target_index() routine
cpufreq: loongson2: Covert to light weight ->target_index() routine
cpufreq: maple: Covert to light weight ->target_index() routine
cpufreq: omap: Covert to light weight ->target_index() routine
cpufreq: p4: Covert to light weight ->target_index() routine
cpufreq: pasemi: Covert to light weight ->target_index() routine
cpufreq: pmac32: Covert to light weight ->target_index() routine
cpufreq: powernow: Covert to light weight ->target_index() routine
cpufreq: ppc: Covert to light weight ->target_index() routine
cpufreq: pxa: Covert to light weight ->target_index() routine
cpufreq: s3c2416: Covert to light weight ->target_index() routine
cpufreq: s3c64xx: Covert to light weight ->target_index() routine
cpufreq: s5pv210: Covert to light weight ->target_index() routine
cpufreq: sa11x0: Covert to light weight ->target_index() routine
cpufreq: sc520: Covert to light weight ->target_index() routine
cpufreq: sparc: Covert to light weight ->target_index() routine
cpufreq: SPEAr: Covert to light weight ->target_index() routine
cpufreq: speedstep: Covert to light weight ->target_index() routine
cpufreq: tegra: Covert to light weight ->target_index() routine
Documentation/cpu-freq/cpu-drivers.txt | 27 ++++++++++------
Documentation/cpu-freq/governors.txt | 4 +--
arch/arm/mach-davinci/Kconfig | 1 -
arch/arm/mach-pxa/Kconfig | 3 --
arch/arm/mach-sa1100/generic.c | 20 ------------
arch/arm/mach-sa1100/generic.h | 2 --
arch/arm/mach-ux500/Kconfig | 1 -
arch/blackfin/Kconfig | 1 -
arch/cris/Kconfig | 2 --
drivers/cpufreq/Kconfig | 11 -------
drivers/cpufreq/Kconfig.arm | 11 -------
drivers/cpufreq/Kconfig.powerpc | 6 ----
drivers/cpufreq/Kconfig.x86 | 13 --------
drivers/cpufreq/Makefile | 5 +--
drivers/cpufreq/acpi-cpufreq.c | 21 ++++---------
drivers/cpufreq/arm_big_little.c | 17 +++-------
drivers/cpufreq/at32ap-cpufreq.c | 23 +++-----------
drivers/cpufreq/blackfin-cpufreq.c | 17 +++-------
drivers/cpufreq/cpufreq-cpu0.c | 17 ++--------
drivers/cpufreq/cpufreq.c | 57 ++++++++++++++++++++++++++--------
drivers/cpufreq/cris-artpec3-cpufreq.c | 18 ++---------
drivers/cpufreq/cris-etraxfs-cpufreq.c | 17 ++--------
drivers/cpufreq/davinci-cpufreq.c | 16 ++--------
drivers/cpufreq/dbx500-cpufreq.c | 16 ++--------
drivers/cpufreq/e_powersaver.c | 17 ++--------
drivers/cpufreq/elanfreq.c | 34 ++------------------
drivers/cpufreq/exynos-cpufreq.c | 21 ++-----------
drivers/cpufreq/exynos5440-cpufreq.c | 13 ++------
drivers/cpufreq/ia64-acpi-cpufreq.c | 21 ++-----------
drivers/cpufreq/imx6q-cpufreq.c | 17 ++--------
drivers/cpufreq/kirkwood-cpufreq.c | 19 ++----------
drivers/cpufreq/longhaul.c | 13 ++------
drivers/cpufreq/loongson2_cpufreq.c | 21 +++----------
drivers/cpufreq/maple-cpufreq.c | 16 +++-------
drivers/cpufreq/omap-cpufreq.c | 31 ++----------------
drivers/cpufreq/p4-clockmod.c | 18 +++--------
drivers/cpufreq/pasemi-cpufreq.c | 12 ++-----
drivers/cpufreq/pmac32-cpufreq.c | 12 ++-----
drivers/cpufreq/pmac64-cpufreq.c | 17 +++-------
drivers/cpufreq/powernow-k6.c | 35 +++------------------
drivers/cpufreq/powernow-k7.c | 22 +++----------
drivers/cpufreq/powernow-k8.c | 24 +++++---------
drivers/cpufreq/ppc-corenet-cpufreq.c | 15 +++------
drivers/cpufreq/ppc_cbe_cpufreq.c | 12 ++-----
drivers/cpufreq/pxa2xx-cpufreq.c | 13 ++------
drivers/cpufreq/pxa3xx-cpufreq.c | 17 ++--------
drivers/cpufreq/s3c2416-cpufreq.c | 17 +++-------
drivers/cpufreq/s3c64xx-cpufreq.c | 18 +++--------
drivers/cpufreq/s5pv210-cpufreq.c | 54 +++++++++-----------------------
drivers/cpufreq/sa1100-cpufreq.c | 24 +++-----------
drivers/cpufreq/sa1110-cpufreq.c | 26 +++-------------
drivers/cpufreq/sc520_freq.c | 19 ++----------
drivers/cpufreq/sparc-us2e-cpufreq.c | 21 ++-----------
drivers/cpufreq/sparc-us3-cpufreq.c | 23 ++------------
drivers/cpufreq/spear-cpufreq.c | 12 +++----
drivers/cpufreq/speedstep-centrino.c | 26 +++++-----------
drivers/cpufreq/speedstep-ich.c | 24 ++++----------
drivers/cpufreq/speedstep-smi.c | 20 +++---------
drivers/cpufreq/tegra-cpufreq.c | 12 ++-----
drivers/thermal/Kconfig | 1 -
include/linux/cpufreq.h | 4 ++-
61 files changed, 238 insertions(+), 809 deletions(-)
--
1.7.12.rc2.18.g61b472e
From: Mark Brown <broonie(a)linaro.org>
Since the sht15 driver supports operation without an external vref
regulator the driver should use the new devm_regulator_get_optional() to
indicate that a stub regulator should not be provided.
Signed-off-by: Mark Brown <broonie(a)linaro.org>
---
Since devm_regulator_get_optional() is not yet merged either the branch
adding it would need be be merged into the hwmon tree or I'd need to
apply this to the regualtor tree.
drivers/hwmon/sht15.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/hwmon/sht15.c b/drivers/hwmon/sht15.c
index 883d291..97cd45a 100644
--- a/drivers/hwmon/sht15.c
+++ b/drivers/hwmon/sht15.c
@@ -957,7 +957,7 @@ static int sht15_probe(struct platform_device *pdev)
* If a regulator is available,
* query what the supply voltage actually is!
*/
- data->reg = devm_regulator_get(data->dev, "vcc");
+ data->reg = devm_regulator_get_optional(data->dev, "vcc");
if (!IS_ERR(data->reg)) {
int voltage;
--
1.8.4.rc2
Almost all drivers set policy->cur with current cpu frequency in their ->init()
part. This can be done for all of them at core level and so they wouldn't need
to do it.
This patchset adds supporting code in cpufreq core for calling get() after we have
called init() for a policy. Also fixes all drivers accordingly.
These drivers were still doing some stuff which isn't required and was done by
core already. And that is cleaned as well.
This is Fourth part of my cleanup work for CPUFreq, first three are (And
obviously its rebased over them):
1: cpufreq: Introduce cpufreq_table_validate_and_show()
https://lkml.org/lkml/2013/8/8/263
2: cpufreq: define generic routines for cpufreq drivers
https://lkml.org/lkml/2013/8/10/48
3. CPUFreq: Implement light weight ->target(): for 3.13
https://lkml.org/lkml/2013/8/13/349
All these are pushed here:
https://git.linaro.org/gitweb?p=people/vireshk/linux.git;a=shortlog;h=refs/…
--
viresh
Cc: Andrew Lunn <andrew(a)lunn.ch>
Cc: David S. Miller <davem(a)davemloft.net>
Cc: Dmitry Eremin-Solenikov <dbaryshkov(a)gmail.com>
Cc: Eric Miao <eric.y.miao(a)gmail.com>
Cc: Hans-Christian Egtvedt <egtvedt(a)samfundet.no>
Cc: Jesper Nilsson <jesper.nilsson(a)axis.com>
Cc: John Crispin <blogic(a)openwrt.org>
Cc: Kukjin Kim <kgene.kim(a)samsung.com>
Cc: Linus Walleij <linus.walleij(a)linaro.org>
Cc: linux-cris-kernel(a)axis.com
Cc: linux-sh(a)vger.kernel.org
Cc: Mikael Starvik <starvik(a)axis.com>
Cc: Paul Mundt <lethal(a)linux-sh.org>
Cc: Russell King <linux(a)arm.linux.org.uk>
Cc: Santosh Shilimkar <santosh.shilimkar(a)ti.com>
Cc: Sekhar Nori <nsekhar(a)ti.com>
Cc: Shawn Guo <shawn.guo(a)linaro.org>
Cc: spear-devel(a)list.st.com
Cc: Stephen Warren <swarren(a)nvidia.com>
Cc: Steven Miao <realmz6(a)gmail.com>
Cc: Tony Luck <tony.luck(a)intel.com>
Viresh Kumar (37):
cpufreq: call cpufreq_driver->get() after calling ->init()
cpufreq: acpi: don't initialize part of policy that is set by core
too
cpufreq: arm_big_little: don't initialize part of policy that is set
by core too
cpufreq: at32ap: don't initialize part of policy that is set by core
too
cpufreq: blackfin: don't initialize part of policy that is set by
core too
cpufreq: cpu0: don't initialize part of policy that is set by core
too
cpufreq: nforce2: don't initialize part of policy that is set by core
too
cpufreq: cris: don't initialize part of policy that is set by core
too
cpufreq: davinci: don't initialize part of policy that is set by core
too
cpufreq: dbx500: don't initialize part of policy that is set by core
too
cpufreq: e_powersaver: don't initialize part of policy that is set by
core too
cpufreq: elanfreq: don't initialize part of policy that is set by
core too
cpufreq: exynos: don't initialize part of policy that is set by core
too
cpufreq: gx: don't initialize part of policy that is set by core too
cpufreq: ia64-acpi: don't initialize part of policy that is set by
core too
cpufreq: imx6q: don't initialize part of policy that is set by core
too
cpufreq: integrator: don't initialize part of policy that is set by
core too
cpufreq: kirkwood: don't initialize part of policy that is set by
core too
cpufreq: longhaul: don't initialize part of policy that is set by
core too
cpufreq: loongson2: don't initialize part of policy that is set by
core too
cpufreq: maple: don't initialize part of policy that is set by core
too
cpufreq: omap: don't initialize part of policy that is set by core
too
cpufreq: p4: don't initialize part of policy that is set by core too
cpufreq: pcc: don't initialize part of policy that is set by core too
cpufreq: pmac: don't initialize part of policy that is set by core
too
cpufreq: powernow: don't initialize part of policy that is set by
core too
cpufreq: ppc: don't initialize part of policy that is set by core too
cpufreq: pxa: don't initialize part of policy that is set by core too
cpufreq: s3c: don't initialize part of policy that is set by core too
cpufreq: s5pv210: don't initialize part of policy that is set by core
too
cpufreq: sa11x0: don't initialize part of policy that is set by core
too
cpufreq: sc520_freq: don't initialize part of policy that is set by
core too
cpufreq: sh: don't initialize part of policy that is set by core too
cpufreq: spear: don't initialize part of policy that is set by core
too
cpufreq: speedstep: don't initialize part of policy that is set by
core too
cpufreq: tegra: don't initialize part of policy that is set by core
too
cpufreq: unicore2: don't initialize part of policy that is set by
core too
drivers/cpufreq/acpi-cpufreq.c | 1 -
drivers/cpufreq/arm_big_little.c | 2 --
drivers/cpufreq/at32ap-cpufreq.c | 12 ++++--------
drivers/cpufreq/blackfin-cpufreq.c | 1 -
drivers/cpufreq/cpufreq-cpu0.c | 1 -
drivers/cpufreq/cpufreq-nforce2.c | 1 -
drivers/cpufreq/cpufreq.c | 11 +++++++++++
drivers/cpufreq/cris-artpec3-cpufreq.c | 1 -
drivers/cpufreq/cris-etraxfs-cpufreq.c | 1 -
drivers/cpufreq/davinci-cpufreq.c | 2 --
drivers/cpufreq/dbx500-cpufreq.c | 5 -----
drivers/cpufreq/e_powersaver.c | 1 -
drivers/cpufreq/elanfreq.c | 1 -
drivers/cpufreq/exynos-cpufreq.c | 2 --
drivers/cpufreq/exynos5440-cpufreq.c | 1 -
drivers/cpufreq/gx-suspmod.c | 5 +----
drivers/cpufreq/ia64-acpi-cpufreq.c | 1 -
drivers/cpufreq/imx6q-cpufreq.c | 1 -
drivers/cpufreq/integrator-cpufreq.c | 5 ++---
drivers/cpufreq/kirkwood-cpufreq.c | 1 -
drivers/cpufreq/longhaul.c | 1 -
drivers/cpufreq/loongson2_cpufreq.c | 2 --
drivers/cpufreq/maple-cpufreq.c | 1 -
drivers/cpufreq/omap-cpufreq.c | 4 ----
drivers/cpufreq/p4-clockmod.c | 1 -
drivers/cpufreq/pcc-cpufreq.c | 7 -------
drivers/cpufreq/pmac32-cpufreq.c | 1 -
drivers/cpufreq/pmac64-cpufreq.c | 1 -
drivers/cpufreq/powernow-k6.c | 1 -
drivers/cpufreq/powernow-k7.c | 2 --
drivers/cpufreq/powernow-k8.c | 3 ---
drivers/cpufreq/ppc-corenet-cpufreq.c | 2 --
drivers/cpufreq/pxa2xx-cpufreq.c | 2 --
drivers/cpufreq/pxa3xx-cpufreq.c | 7 +++----
drivers/cpufreq/s3c2416-cpufreq.c | 2 --
drivers/cpufreq/s3c24xx-cpufreq.c | 5 -----
drivers/cpufreq/s3c64xx-cpufreq.c | 2 --
drivers/cpufreq/s5pv210-cpufreq.c | 2 --
drivers/cpufreq/sa1100-cpufreq.c | 1 -
drivers/cpufreq/sa1110-cpufreq.c | 1 -
drivers/cpufreq/sc520_freq.c | 1 -
drivers/cpufreq/sh-cpufreq.c | 2 --
drivers/cpufreq/spear-cpufreq.c | 2 --
drivers/cpufreq/speedstep-centrino.c | 5 -----
drivers/cpufreq/speedstep-ich.c | 15 +--------------
drivers/cpufreq/speedstep-smi.c | 13 -------------
drivers/cpufreq/tegra-cpufreq.c | 3 +--
drivers/cpufreq/unicore2-cpufreq.c | 1 -
48 files changed, 23 insertions(+), 123 deletions(-)
--
1.7.12.rc2.18.g61b472e
From: Mark Brown <broonie(a)linaro.org>
The Arndale has a SMSC USB3503 connected in hardware only mode like a PHY,
support it using the usb-nop-xceiv binding.
Note that due to a regrettable decision to use a regulator to represent
the reset signal this uses a fixed voltage regulator to do that, there
is a plan to use the reset controller binding once that is merged so it
does not seem worthwhile to fix the usb-nop-xceiv driver at this point.
Signed-off-by: Mark Brown <broonie(a)linaro.org>
Tested-by: Tushar Behera <tushar.behera(a)linaro.org>
---
arch/arm/boot/dts/exynos5250-arndale.dts | 14 ++++++++++++++
1 file changed, 14 insertions(+)
diff --git a/arch/arm/boot/dts/exynos5250-arndale.dts b/arch/arm/boot/dts/exynos5250-arndale.dts
index 96d528d..2428ffd 100644
--- a/arch/arm/boot/dts/exynos5250-arndale.dts
+++ b/arch/arm/boot/dts/exynos5250-arndale.dts
@@ -539,4 +539,18 @@
rtc {
status = "okay";
};
+
+ usb_hub_bus {
+ compatible = "simple-bus";
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ // SMSC USB3503 connected in hardware only mode as a PHY
+ usb_hub: usb_hub {
+ compatible = "smsc,usb3503a";
+
+ reset-gpios = <&gpx3 5 1>;
+ connect-gpios = <&gpd1 7 1>;
+ };
+ };
};
--
1.8.4.rc2