[PATCH v2 3/3] x86/entry/64: Move #BP from IST to the IRQ stack

2015-07-24 Thread Andy Lutomirski
There's nothing IST-worthy about #BP/int3. We don't allow kprobes in the small handful of places in the kernel that run at CPL0 with an invalid stack, and 32-bit kernels have used normal interrupt gates for #BP forever. Furthermore, we don't allow kprobes in places that have usergs while in

[PATCH v2 0/3] x86_64: Make int3 non-magical

2015-07-24 Thread Andy Lutomirski
int3 uses IST and the paranoid gsbase path. Neither is necessary, although the IST stack may currently be necessary to avoid stack overruns. Clean up IRQ stacks, make them NMI safe, teach idtentry to use irqstacks if requested, and move int3 to the IRQ stack. This prepares us to return from

[PATCH v2 1/3] x86/entry/64: Refactor IRQ stacks and make them NMI-safe

2015-07-24 Thread Andy Lutomirski
This will allow IRQ stacks to nest inside NMIs or similar entries that can happen during IRQ stack setup or teardown. The Xen code here has a confusing comment. The new macros won't work correctly if they're invoked with IRQs on. Add a check under CONFIG_DEBUG_ENTRY to detect that.

[PATCH v2 2/3] x86/entry/64: Teach idtentry to use the IRQ stack

2015-07-24 Thread Andy Lutomirski
We don't specifically need IST for things like kprobes, but we do want to avoid rare, surprising extra stack usage if a kprobe hits with a deep stack. Teach idtentry to use the IRQ stack for selected entries. This implementation uses the IRQ stack even if we entered from user mode. This

[PATCH v4 2/3] x86/ldt: Make modify_ldt optional

2015-07-24 Thread Andy Lutomirski
The modify_ldt syscall exposes a large attack surface and is unnecessary for modern userspace. Make it optional. Signed-off-by: Andy Lutomirski --- arch/x86/Kconfig | 17 + arch/x86/include/asm/mmu.h | 2 ++ arch/x86/include/asm/mmu_context.h | 31

[PATCH v4 3/3] selftests/x86, x86/ldt: Add a selftest for modify_ldt

2015-07-24 Thread Andy Lutomirski
This tests general modify_ldt behavior (only writes, so far) as well as synchronous updates via IPI. It fails on old kernels. I called this ldt_gdt because I'll add set_thread_area tests to it at some point. Signed-off-by: Andy Lutomirski --- tools/testing/selftests/x86/Makefile | 2 +-

[PATCH v4 0/3] x86: modify_ldt improvement, test, and config option

2015-07-24 Thread Andy Lutomirski
Here's v3. It fixes the "dazed and confused" issue, I hope. It's also probably a good general attack surface reduction, and it replaces some scary code with IMO less scary code. Also, servers and embedded systems should probably turn off modify_ldt. This makes that possible. Xen people, can

[PATCH v4 1/3] x86/ldt: Make modify_ldt synchronous

2015-07-24 Thread Andy Lutomirski
modify_ldt has questionable locking and does not synchronize threads. Improve it: redesign the locking and synchronize all threads' LDTs using an IPI on all modifications. This will dramatically slow down modify_ldt in multithreaded programs, but there shouldn't be any multithreaded programs

Re: [PATCH V2 net-next 0/3] ARM BPF JIT features

2015-07-24 Thread David Miller
From: Nicolas Schichan Date: Tue, 21 Jul 2015 14:16:37 +0200 > This serie adds support for more instructions to the ARM BPF JIT "series" > namely skb netdevice type retrieval, skb payload offset retrieval, and > skb packet type retrieval. > > This allows 35 tests to use the JIT instead of 29

Re: [PATCH 1/3] x86/entry/64: Refactor IRQ stacks and make then NMI-safe

2015-07-24 Thread Andy Lutomirski
On Fri, Jul 24, 2015 at 9:32 PM, Borislav Petkov wrote: > On Fri, Jul 24, 2015 at 09:28:47PM -0700, Andy Lutomirski wrote: >> Yeah, I'm going to submit v2 with the simple approach. I admit I'm >> rather fond of xadd as a way to switch rsp and set a flag at the same >> time, though :) > > I know

Re: [PATCH v3 1/3] x86/ldt: Make modify_ldt synchronous

2015-07-24 Thread Andy Lutomirski
On Fri, Jul 24, 2015 at 9:13 PM, Boris Ostrovsky wrote: > > > On 07/22/2015 06:20 PM, Boris Ostrovsky wrote: >> >> On 07/22/2015 03:23 PM, Andy Lutomirski wrote: >>> >>> >>> +error = -ENOMEM; >>> +new_ldt = alloc_ldt_struct(newsize); >>> +if (!new_ldt) >>> goto out_unlock;

Re: [PATCH v3 1/3] x86/ldt: Make modify_ldt synchronous

2015-07-24 Thread Andy Lutomirski
On Fri, Jul 24, 2015 at 8:29 AM, Borislav Petkov wrote: > Let it stick out: > > if (!cpumask_equal(mm_cpumask(current_mm), > cpumask_of(smp_processor_id( > smp_call_function(flush_ldt, current_mm, 1); I see your wide terminal and raise you a complete rewrite of that

Re: [PATCH 1/3] x86/entry/64: Refactor IRQ stacks and make then NMI-safe

2015-07-24 Thread Borislav Petkov
On Fri, Jul 24, 2015 at 09:28:47PM -0700, Andy Lutomirski wrote: > Yeah, I'm going to submit v2 with the simple approach. I admit I'm > rather fond of xadd as a way to switch rsp and set a flag at the same > time, though :) I know you are. But people will rip your head out if you added 60

Re: [PATCH 1/3] x86/entry/64: Refactor IRQ stacks and make then NMI-safe

2015-07-24 Thread Andy Lutomirski
On Fri, Jul 24, 2015 at 9:16 PM, Borislav Petkov wrote: > On Fri, Jul 24, 2015 at 11:02:51AM -0700, Andy Lutomirski wrote: >> So really the only difference between this simple approach (which is >> more or less what we do now) and my fancy approach is that a kernel >> instruction breakpoint will

Re: [PATCH 1/3] x86/entry/64: Refactor IRQ stacks and make then NMI-safe

2015-07-24 Thread Borislav Petkov
On Fri, Jul 24, 2015 at 11:02:51AM -0700, Andy Lutomirski wrote: > So really the only difference between this simple approach (which is > more or less what we do now) and my fancy approach is that a kernel > instruction breakpoint will cause do_debug to run on the initial stack > instead of the

Re: [PATCH v3 1/3] x86/ldt: Make modify_ldt synchronous

2015-07-24 Thread Boris Ostrovsky
On 07/22/2015 06:20 PM, Boris Ostrovsky wrote: On 07/22/2015 03:23 PM, Andy Lutomirski wrote: +error = -ENOMEM; +new_ldt = alloc_ldt_struct(newsize); +if (!new_ldt) goto out_unlock; -} -fill_ldt(, _info); -if (oldmode) -ldt.avl = 0; +if

[PATCH v2] power_supply: bq24735: Convert to using managed resources

2015-07-24 Thread Vaishali Thakkar
Use managed resource functions like devm_kasprintf and devm_power_supply_register in bq24735_charger_probe. To be compatible with the change, replace various gotos by direct returns and drop unneeded labels. Also, remove bq24735_charger_remove as it is now redundant. Signed-off-by: Vaishali

[PATCHv2] clk: socfpga: Add a second parent option for the dbg_base_clk

2015-07-24 Thread dinguyen
From: Dinh Nguyen The debug base clock can be bypassed from the main PLL to the OSC1 clock. The bypass register is the staysoc1(0x10) register that is in the clock manager. This patch adds the option to get the correct parent for the debug base clock. Signed-off-by: Dinh Nguyen --- v2: remove

Re:REGARDS

2015-07-24 Thread Alexander Flockhart
Dear Friend , I have a good business proposal for you , it's easy and no risk involve, please get back to me for brief details Regards Alexander Flockhart -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org

Re: [PATCH v7 4/5] ARM: dts: vf610twr: add NAND flash controller peripherial

2015-07-24 Thread Shawn Guo
On Fri, Jul 24, 2015 at 03:16:23PM +0200, Stefan Agner wrote: > This adds the NAND flash controller (NFC) peripherial. The driver > supports the SLC NAND chips found on Freescale's Vybrid Tower System > Module. The Micron NAND chip on the module needs 4-bit ECC per 512 > byte page. Use 24-bit ECC

Re: [PATCH v12 4/6] arm/dts/ls1021a: Add DCU dts node

2015-07-24 Thread Shawn Guo
On Fri, Jul 24, 2015 at 06:34:12PM +0800, Jianwei Wang wrote: > Add DCU node, DCU is a display controller of Freescale > named 2D-ACE. > > Signed-off-by: Alison Wang > Signed-off-by: Xiubo Li > Signed-off-by: Jianwei Wang For dts patches sent to me, please use prefix like "ARM: dts: ls1021a:

Re: [PATCH] mn10300: time: Provide 64-bit persistent clock time

2015-07-24 Thread John Stultz
On Mon, Jul 20, 2015 at 5:45 PM, Xunlei Pang wrote: > From: Xunlei Pang > > As part of addressing the "y2038 problem" for in-kernel uses, > convert update_persistent_clock() to update_persistent_clock64(), > read_persistent_clock() to read_persistent_clock64() using > timespec64 for MN10300.

Re: [PATCH v3 3/3] dt-binding:Documents the mbigen bindings

2015-07-24 Thread majun (F)
Hi Mark: 在 2015/7/21 0:38, Mark Rutland 写道: +The mbigen and devices connect to mbigen have the following properties: >> The mbigen chip structrue likes below: >> >> mbigen_chip(domain) >> ||--| >> mbigen_node0 mbigen_node1

[PATCH v2 05/25] arch, drivers: don't include directly, use instead

2015-07-24 Thread Dan Williams
Preparation for uniform definition of ioremap, ioremap_wc, ioremap_wt, and ioremap_cache, tree-wide. Acked-by: Christoph Hellwig Signed-off-by: Dan Williams --- arch/arm/mach-shmobile/pm-rcar.c|2 +- arch/ia64/kernel/cyclone.c |2 +- drivers/isdn/icn/icn.h

[PATCH] fs/char_dev.c: fix incorrect documentation for unregister_chrdev_region

2015-07-24 Thread Partha Pratim Mukherjee
The current documentation for unregister_chrdev_region says that it return a range of device numbers which is incorrect. Instead it unregister a range of device numbers. Fix the documentation to make this clear. Signed-off-by: Partha Pratim Mukherjee --- fs/char_dev.c |2 +- 1 file changed,

[PATCH v2 14/25] toshiba laptop: replace ioremap_cache with ioremap

2015-07-24 Thread Dan Williams
With ioremap_cache being replaced with memremap there is no longer a guarantee that a mapping will silently fall back to an uncached mapping. Explicitly use a vanilla ioremap() for this short lived mapping. Cc: Arnd Bergmann Cc: Greg Kroah-Hartman Cc: Jonathan Buzzard Signed-off-by: Dan

[PATCH v2 15/25] memconsole: fix __iomem mishandling, switch to memremap

2015-07-24 Thread Dan Williams
The memconsole driver is not using proper accessors for __iomem. Switch to memremap to fix this issue, and this also prepares the driver for the removal of ioremap_cache. Cc: Mike Waychison Signed-off-by: Dan Williams --- drivers/firmware/google/memconsole.c |7 --- 1 file changed, 4

[PATCH v2 09/25] arm: switch from ioremap_cache to memremap

2015-07-24 Thread Dan Williams
In preparation for deprecating ioremap_cache() convert its usage in arch/arm[64]/ to memremap. Cc: Russell King Signed-off-by: Dan Williams --- arch/arm/include/asm/xen/page.h|4 ++-- arch/arm64/include/asm/acpi.h |5 + arch/arm64/include/asm/dmi.h |8

[PATCH v2 19/25] pxa2xx-flash: switch from ioremap_cache to memremap

2015-07-24 Thread Dan Williams
In preparation for deprecating ioremap_cache() convert its usage in pxa2xx-flash to memremap. Cc: David Woodhouse Cc: Brian Norris Signed-off-by: Dan Williams --- drivers/mtd/maps/pxa2xx-flash.c |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git

[PATCH v2 23/25] arch: remove ioremap_cache, replace with arch_memremap

2015-07-24 Thread Dan Williams
Now that all call sites for ioremap_cache() have been converted to memremap(MEMREMAP_CACHE) we can now proceed with removing the implementation in the archs. This amounts to replacing the per-arch ioremap_cache() implementation with arch_memremap. Cc: Arnd Bergmann Cc: Russell King Cc: Tony

[PATCH v2 25/25] pmem: convert to generic memremap

2015-07-24 Thread Dan Williams
Update memremap_pmem() to query the architecture for the mapping type of the given persistent memory range and then pass those flags to generic memremap(). arch_memremap_pmem_flags() is provided an address range to evaluate in the event an arch has a need for different mapping types by address

[PATCH v2 22/25] pmem: switch from ioremap_wt to memremap

2015-07-24 Thread Dan Williams
In preparation for deprecating ioremap_wt() convert its usage in the PMEM API to memremap. Cc: Ross Zwisler Signed-off-by: Dan Williams --- include/linux/pmem.h |2 +- tools/testing/nvdimm/Kbuild |4 ++-- tools/testing/nvdimm/test/iomap.c | 34

[PATCH v2 21/25] fbdev: switch from ioremap_wt to memremap

2015-07-24 Thread Dan Williams
In preparation for deprecating ioremap_wt() convert its usage in drivers/video/fbdev to memremap. Cc: Jean-Christophe Plagniol-Villard Cc: Tomi Valkeinen Cc: linux-fb...@vger.kernel.org Signed-off-by: Dan Williams --- drivers/video/fbdev/amifb.c |5 +++-- drivers/video/fbdev/atafb.c |

[PATCH v2 24/25] arch: remove ioremap_wt, replace with arch_memremap

2015-07-24 Thread Dan Williams
Now that all call sites for ioremap_wt() have been converted to memremap(MEMREMAP_WT) we can now proceed with removing the implementation in the archs. This amounts to replacing the per-arch ioremap_wt() implementation with arch_memremap. Cc: Arnd Bergmann Cc: Russell King Cc: Tony Luck Cc:

[PATCH v2 16/25] visorbus: switch from ioremap_cache to memremap

2015-07-24 Thread Dan Williams
In preparation for deprecating ioremap_cache() convert its usage in visorbus to memremap. Cc: Benjamin Romer Cc: David Kershner Cc: Greg Kroah-Hartman Signed-off-by: Dan Williams --- drivers/staging/unisys/visorbus/visorchannel.c | 16 +---

[PATCH v2 18/25] libnvdimm, pmem: switch from ioremap_cache to memremap

2015-07-24 Thread Dan Williams
In preparation for deprecating ioremap_cache() convert its usage in libnvdimm and the PMEM API to memremap. Signed-off-by: Dan Williams --- arch/x86/include/asm/io.h |7 +-- arch/x86/mm/ioremap.c |6 ++ tools/testing/nvdimm/Kbuild |2 +-

[PATCH v2 11/25] gma500: switch from acpi_os_ioremap to ioremap

2015-07-24 Thread Dan Williams
acpi_os_ioremap uses cached mappings, however it appears that gma500 wants to read dynamic platform state. Switch to ioremap() to prevent it reading stale state from cache. Cc: David Airlie Cc: dri-de...@lists.freedesktop.org Signed-off-by: Dan Williams --- drivers/gpu/drm/gma500/opregion.c |

[PATCH v2 20/25] sfi: switch from ioremap_cache to memremap

2015-07-24 Thread Dan Williams
In preparation for deprecating ioremap_cache() convert its usage in sfi to memremap. It's a bit awkward that we go and add back a fake __iomem annotation, but this is to keep consistency with early_ioremap() which does not have a 'memremap' flavor. Cc: Len Brown Signed-off-by: Dan Williams ---

[PATCH v2 10/25] x86: switch from ioremap_cache to memremap

2015-07-24 Thread Dan Williams
In preparation for deprecating ioremap_cache() convert its usage in arch/x86/ to memremap. Cc: Thomas Gleixner Cc: H. Peter Anvin Cc: Ingo Molnar Cc: Borislav Petkov Signed-off-by: Dan Williams --- arch/x86/include/asm/efi.h |3 ++- arch/x86/kernel/crash_dump_64.c |6 +++---

[PATCH v2 08/25] arch: introduce memremap()

2015-07-24 Thread Dan Williams
Existing users of ioremap_cache() are mapping memory that is known in advance to not have i/o side effects. These users are forced to cast away the __iomem annotation, or otherwise neglect to fix the sparse errors thrown when dereferencing pointers to this memory. Provide memremap() as a non

[PATCH v2 17/25] intel-iommu: switch from ioremap_cache to memremap

2015-07-24 Thread Dan Williams
In preparation for deprecating ioremap_cache() convert its usage in intel-iommu to memremap. This also eliminates the mishandling of the __iomem annotation in the implementation. Cc: David Woodhouse Cc: Joerg Roedel Signed-off-by: Dan Williams --- drivers/iommu/intel-iommu.c | 10

[PATCH v2 12/25] i915: switch from acpi_os_ioremap to ioremap

2015-07-24 Thread Dan Williams
acpi_os_ioremap uses cached mappings, however it appears that i915 wants to read dynamic platform state. Switch to ioremap() to prevent it reading stale state from cache. Cc: Daniel Vetter Cc: Jani Nikula Cc: intel-...@lists.freedesktop.org Cc: David Airlie Cc: dri-de...@lists.freedesktop.org

[PATCH v2 13/25] acpi: switch from ioremap_cache to memremap

2015-07-24 Thread Dan Williams
In preparation for deprecating ioremap_cache() convert its usage in drivers/acpi and include/acpi/ to memremap. This includes dropping the __iomem annotation throughout ACPI since the memremap can be treated as a normal memory pointer. Finally, memremap automatically handles requests to map

[PATCH v2 04/25] mm: enhance region_is_ram() to distinguish 'unknown' vs 'mixed'

2015-07-24 Thread Dan Williams
region_is_ram() is used to prevent the establishment of aliased mappings to physical "System RAM" with incompatible cache settings. However, it uses "-1" to indicate both "unknown" memory ranges (ranges not described by platform firmware) and "mixed" ranges (where the parameters describe a range

[PATCH v2 03/25] mm: Fix bugs in region_is_ram()

2015-07-24 Thread Dan Williams
From: Toshi Kani region_is_ram() looks up the iomem_resource table to check if a target range is in RAM. However, it always returns with -1 due to invalid range checks. It always breaks the loop at the first entry of the table. Another issue is that it compares p->flags and flags, but it

[PATCH v2 07/25] intel_iommu: fix leaked ioremap mapping

2015-07-24 Thread Dan Williams
iommu_load_old_irte() appears to leak the old_irte mapping after use. Cc: Joerg Roedel Signed-off-by: Dan Williams --- drivers/iommu/intel_irq_remapping.c |2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/iommu/intel_irq_remapping.c b/drivers/iommu/intel_irq_remapping.c index

[PATCH v2 06/25] cleanup IORESOURCE_CACHEABLE vs ioremap()

2015-07-24 Thread Dan Williams
Quoting Arnd: I was thinking the opposite approach and basically removing all uses of IORESOURCE_CACHEABLE from the kernel. There are only a handful of them.and we can probably replace them all with hardcoded ioremap_cached() calls in the cases they are actually useful. All

[PATCH v2 02/25] mm, x86: Remove region_is_ram() call from ioremap

2015-07-24 Thread Dan Williams
From: Toshi Kani __ioremap_caller() calls region_is_ram() to walk through the iomem_resource table to check if a target range is in RAM, which was added to improve the lookup performance over page_is_ram() (commit 906e36c5c717 "x86: use optimized ioresource lookup in ioremap function").

[PATCH v2 00/25] replace ioremap_{cache|wt} with memremap

2015-07-24 Thread Dan Williams
Changes since v1 [1]: 1/ Drop the attempt at unifying ioremap() prototypes, just focus on converting ioremap_cache and ioremap_wt over to memremap (Christoph) 2/ Drop the unrelated cleanups to use %pa in __ioremap_caller (Thomas) 3/ Add support for memremap() attempts on "System RAM" to

[PATCH v2 01/25] mm, x86: Fix warning in ioremap RAM check

2015-07-24 Thread Dan Williams
From: Toshi Kani __ioremap_caller() calls __ioremap_check_ram() through walk_system_ram_range() to check if a target range is in RAM. __ioremap_check_ram() has WARN_ONCE() in a wrong place where it warns when the given range is not RAM. This misplaced warning is not exposed since

Re: [PATCH] clk: socfpga: Add a second parent option for the dbg_base_clk

2015-07-24 Thread Dinh Nguyen
On 7/24/15 4:41 PM, Stephen Boyd wrote: > On 07/22, dingu...@opensource.altera.com wrote: >> diff --git a/arch/arm/boot/dts/socfpga.dtsi b/arch/arm/boot/dts/socfpga.dtsi >> index 80f924d..7d5db54 100644 >> --- a/arch/arm/boot/dts/socfpga.dtsi >> +++ b/arch/arm/boot/dts/socfpga.dtsi >> @@ -164,7

sys_pread64 data error: sys_pread64 return success but buffer data wrong with transparent hugepage enabled in multi-thread application

2015-07-24 Thread Jaden Liang
Hi all, We have a multi-thread application to read file with pread DIRECT_IO from file. The buffer and file offset are both 4K aligned. And sometimes the threads will call system() to do some command while running. With some debug, there are some chances sys_pread64 return success, but the

Re: [PATCH v2 0/5] bpf: Introduce the new ability of eBPF programs to access hardware PMU counter

2015-07-24 Thread xiakaixu
于 2015/7/24 7:33, Daniel Borkmann 写道: > On 07/22/2015 10:09 AM, Kaixu Xia wrote: >> Previous patch v1 url: >> https://lkml.org/lkml/2015/7/17/287 > > [ Sorry to chime in late, just noticed this series now as I wasn't in Cc for > the core BPF changes. More below ... ] Sorry about this, will add

Re: [PATCH v2 1/5] clk: qcom: Enable gpll0_vote rate propagation on MSM8916

2015-07-24 Thread Georgi Djakov
On 24.07.15 20:25, Stephen Boyd wrote: > On 07/24/2015 09:58 AM, Georgi Djakov wrote: >> Currently we are missing the SET_RATE_PARENT flag on gpll0_vote and >> as a result of that, when it has a child with SET_RATE_PARENT flag, >> the rate of the child is not propagated up to the gpll0. Fix that

RE: [PATCH v6 0/3] cpufreq: Use cpufreq-dt driver for Exynos3250

2015-07-24 Thread Kukjin Kim
Krzysztof Kozlowski wrote: > > On 24.07.2015 12:40, Kukjin Kim wrote: > > On 07/24/15 09:30, Michael Turquette wrote: > >> Quoting Kukjin Kim (2015-07-07 07:43:31) > >>> Bartlomiej Zolnierkiewicz wrote: > > > > [...] > > > > Chanwoo Choi (3): > > clk: samsung: exynos3250: Add cpu clock

RE: [GIT PULL] ARM: defconfig: Improvements for 4.3

2015-07-24 Thread Kukjin Kim
Krzysztof Kozlowski > > 2015-07-17 15:51 GMT+09:00 Krzysztof Kozlowski : > > Dear Kukjin, > > > > Few defconfig related changes. > > > > Description along with a tag. > > You can find them also on the lists with my reviewed-by. > > > > Best regards, > > Krzysztof > > Any comments on this pull

RE: [PATCH 2/9] ARM: multi_v7_defconfig: Enable max77802 regulator, rtc and clock drivers

2015-07-24 Thread Kukjin Kim
Olof Johansson wrote: > > Hi, > Hi, > On Fri, Jul 17, 2015 at 11:47 AM, Javier Martinez Canillas > wrote: > > Hello Olof, > > > > On Fri, Jul 17, 2015 at 6:49 PM, Olof Johansson wrote: > >> On Thu, Jul 16, 2015 at 09:42:47AM +0900, Krzysztof Kozlowski wrote: > >>> On 16.07.2015 00:38, Javier

Re: [PATCH] cleanups for crypto/wp512.c

2015-07-24 Thread Herbert Xu
On Fri, Jul 24, 2015 at 06:50:15PM +0200, Ahmed Mohamed Abd EL Mawgood wrote: > > fixing all errors and warning of checkpatch.pl for > crypto/wp512.c > Signed-off-by: Ahmed Mohamed Nack. Please do not generate patches purely based on checkpatch. Thanks, -- Email: Herbert Xu Home Page:

Re: [PATCH] code cleanups for crypto/blkcipher.c

2015-07-24 Thread Herbert Xu
On Fri, Jul 24, 2015 at 04:04:32PM +0200, Ahmed Mohamed Abd EL Mawgood wrote: > > @@ -68,6 +68,7 @@ static inline void blkcipher_unmap_dst(struct > blkcipher_walk *walk) > static inline u8 *blkcipher_get_spot(u8 *start, unsigned int len) > { > u8 *end_page = (u8 *)(((unsigned long)(start

RE: [GIT PULL] Non-critical fixes for v4.3

2015-07-24 Thread Kukjin Kim
Krzysztof Kozlowski wrote: > > 2015-07-24 20:04 GMT+09:00 Bartlomiej Zolnierkiewicz > : > > > > Hi, > > > > On Friday, July 24, 2015 03:34:55 PM Krzysztof Kozlowski wrote: > >> Dear Kukjin, > >> > >> Previously you did not picked up the fix for cpufreq memory leak. > >> I am sending it again

Re: [PATCH 0/9] Platform support for thermal management on Junoe

2015-07-24 Thread Viresh Kumar
On 24-07-15, 15:16, Punit Agrawal wrote: > Hi Viresh, > > Viresh Kumar writes: > > > On 22-07-15, 15:02, Punit Agrawal wrote: > >> cpufreq-dt: Supply power coefficient when registering cooling devices > >> cpufreq: arm_big_little: Add support to register a cpufreq cooling > >> device >

[PATCH] kselftests/ftrace : Add event trigger testcases

2015-07-24 Thread Masami Hiramatsu
This adds simple event trigger testcases for ftracetest, which covers following triggers. - traceon-traceoff trigger - enable/disable_event trigger - snapshot trigger - stacktrace trigger - trigger filters Signed-off-by: Masami Hiramatsu Cc: Steven Rostedt Cc: Ingo Molnar Cc: Shuah Khan

[GIT PULL] MTD updates for 4.2-rc4

2015-07-24 Thread Brian Norris
Hi Linus, The following changes since commit d770e558e21961ad6cfdf0ff7df0eb5d7d4f0754: Linux 4.2-rc1 (2015-07-05 11:01:52 -0700) are available in the git repository at: git://git.infradead.org/linux-mtd.git tags/for-linus-20150724 for you to fetch changes up

Re: [RFC v4 03/25] m68k/atari: Move Atari-specific code out of drivers/char/nvram.c

2015-07-24 Thread Michael Ellerman
On Sat, 2015-07-25 at 10:35 +1000, Finn Thain wrote: > On Fri, 24 Jul 2015, Christian T. Steigies wrote: > > 3b5801864975cf23bcacb52f648e74cc /dev/nvram > > 3b5801864975cf23bcacb52f648e74cc /tmp/nvram > > Thanks for helping with this, Christian. I'll add your name in "Tested-by" > tags on the

Re: [PATCH] drivers/of/fdt.c: replace pr_warning by pr_warn

2015-07-24 Thread long.wanglong
On 2015/7/25 3:00, Rob Herring wrote: > On Tue, Jul 21, 2015 at 3:01 AM, Wang Long wrote: >> Update the last pr_warning callsite in drivers/of. > > That is obvious in the diff, but can you tell me why? Hi Rob, When we use script "./scripts/checkpatch.pl" to check a patch, using pr_warning will

Re: [PATCH v2 2/5] mtd: nand: Qualcomm NAND controller driver

2015-07-24 Thread Stephen Boyd
On 07/21/2015 03:34 AM, Archit Taneja wrote: > diff --git a/drivers/mtd/nand/Kconfig b/drivers/mtd/nand/Kconfig > index 5b2806a..31951fc 100644 > --- a/drivers/mtd/nand/Kconfig > +++ b/drivers/mtd/nand/Kconfig > @@ -538,4 +538,11 @@ config MTD_NAND_HISI504 > help > Enables support

Re: [RFC PATCH perf/core v2 00/16] perf-probe --cache and SDT support

2015-07-24 Thread Masami Hiramatsu
On 2015/07/25 0:52, Arnaldo Carvalho de Melo wrote: > Em Fri, Jul 24, 2015 at 04:55:19PM +0900, Namhyung Kim escreveu: >> On Fri, Jul 24, 2015 at 01:24:53AM +0900, Masami Hiramatsu wrote: >>> On 2015/07/23 23:01, Arnaldo Carvalho de Melo wrote: Em Thu, Jul 23, 2015 at 10:13:22PM +0900, Masami

Re: [RFC v4 03/25] m68k/atari: Move Atari-specific code out of drivers/char/nvram.c

2015-07-24 Thread Michael Schmitz
Hi Christian, good to know this worked - for the record (Finn), this is the kernel with Finn's patch applied. I'll build the missing LVM module so Christian can run the tests on the unpatched kernel as well. Thanks for testing! Michael Am 25.07.15 um 07:07 schrieb Christian T.

Re: [RFC v4 03/25] m68k/atari: Move Atari-specific code out of drivers/char/nvram.c

2015-07-24 Thread Finn Thain
On Fri, 24 Jul 2015, Christian T. Steigies wrote: > Moin, > On Fri, Jul 24, 2015 at 02:56:26PM +1200, Michael Schmitz wrote: > > > > here's what Finn asked me to run as tests: > > > > # dmesg | grep this_id > nvram.out > > # cat /proc/driver/nvram >> nvram.out > > # hexdump -C /dev/nvram >>

[PATCH] Documentation: add new description of path-name lookup.

2015-07-24 Thread NeilBrown
This document is based on three recent lwn.net articles. Some of the introductory material and linkage between articles has been removed, and some time-based descriptions have been revised. Also all links to code have been removed as the code is very close by. Signed-off-by: NeilBrown --- I'm

[PATCH] serial: etraxfs-uart: use mctrl_gpio helpers for handling modem signals

2015-07-24 Thread Niklas Cassel
In order to use the mctrl_gpio helpers, we change the DT bindings: ri-gpios renamed to rng-gpios. cd-gpios renamed to dcd-gpios. However, no in-tree dts/dtsi specifies these, so no worries. Signed-off-by: Niklas Cassel --- .../bindings/serial/axis,etraxfs-uart.txt | 6 +++-

[PATCH] serial: etraxfs-uart: remove empty functions

2015-07-24 Thread Niklas Cassel
Implementing enable_ms is optional by serial_core. check_modem_status is just an empty local function. Signed-off-by: Niklas Cassel --- drivers/tty/serial/etraxfs-uart.c | 10 -- 1 file changed, 10 deletions(-) diff --git a/drivers/tty/serial/etraxfs-uart.c

[RFCv2 2/3] dts: zynq: Add devicetree entry for Xilinx Zynq reset controller.

2015-07-24 Thread Moritz Fischer
Signed-off-by: Moritz Fischer --- arch/arm/boot/dts/zynq-7000.dtsi| 43 - arch/arm/boot/dts/zynq-parallella.dts | 2 +- arch/arm/boot/dts/zynq-zc702.dts| 2 +- arch/arm/boot/dts/zynq-zc706.dts| 2 +- arch/arm/boot/dts/zynq-zed.dts

[RFCv2 3/3] reset: reset-zynq: Adding support for Xilinx Zynq reset controller.

2015-07-24 Thread Moritz Fischer
This adds a reset controller driver to control the Xilinx Zynq SoC's various resets. Signed-off-by: Moritz Fischer --- drivers/reset/Makefile | 1 + drivers/reset/reset-zynq.c | 142 + 2 files changed, 143 insertions(+) create mode 100644

[RFCv2 0/3] Adding support for Zynq Reset Controller

2015-07-24 Thread Moritz Fischer
Hi all, I went ahead and generalized it to support all the resets I could find in the TRM. I don't know if all of them are sensible, so we need to carfully double check that. I also tried to add in the stuff that was pointed out in v1. If this looks good enough for a patch let me know. Thanks

[RFCv2 1/3] docs: dts: Added documentation for Xilinx Zynq Reset Controller bindings.

2015-07-24 Thread Moritz Fischer
Signed-off-by: Moritz Fischer --- Documentation/devicetree/bindings/reset/zynq-reset-pl.txt | 13 + 1 file changed, 13 insertions(+) create mode 100644 Documentation/devicetree/bindings/reset/zynq-reset-pl.txt diff --git a/Documentation/devicetree/bindings/reset/zynq-reset-pl.txt

Re: [PATCH V5 2/2] mtd: spi-nor: Add driver for Cadence Quad SPI Flash Controller.

2015-07-24 Thread vikasm
Hi Graham, On 07/24/2015 10:17 AM, Graham Moore wrote: > Signed-off-by: Graham Moore > --- > V2: use NULL instead of modalias in spi_nor_scan call > V3: Use existing property is-decoded-cs instead of creating duplicate. > V4: Support Micron quad mode by snooping command stream for EVCR command >

Re: X-Gene: Unhandled fault: synchronous external abort in pci_generic_config_read32

2015-07-24 Thread Duc Dang
Hi Bjorn, On Fri, Jul 24, 2015 at 3:42 PM, Bjorn Helgaas wrote: > > I regularly see faults like this on an APM X-Gene: > > U-Boot 2013.04-mustang_sw_1.14.14 (Dec 16 2014 - 15:59:33) > CPU0: APM ARM 64-bit Potenza Rev B0 2400MHz PCP 2400MHz >32 KB ICACHE, 32 KB DCACHE >SOC

[PATCH] staging/xgifb: fix dumpVGAReg compile error if DEBUG is set

2015-07-24 Thread Peter Huewe
If DEBUG is set dumpVGAReg is called and tries to access XGISR which is defined as (xgifb_info->dev_info.P3c4) which is not known within this function. -> add as parameter to dumpVGAReg so xgifb_info becomes known Signed-off-by: Peter Huewe --- drivers/staging/xgifb/XGI_main_26.c | 8

Re: Dealing with the NMI mess

2015-07-24 Thread Linus Torvalds
On Fri, Jul 24, 2015 at 1:51 PM, Peter Zijlstra wrote: > > do_debug() > send_sigtrap() > force_sig_info() > spin_lock_irqsave() > > Now, I don't pretend to understand the condition before send_sigtrap(), > so it _might_ be ok, but it sure as heck could do with a comment. Ugh. As Andy

[PATCH V8 4/5] arm64: apei: implement arch_apei_get_mem_attributes()

2015-07-24 Thread Jonathan (Zhixiong) Zhang
From: "Jonathan (Zhixiong) Zhang" Table 8 of UEFI 2.5 section 2.3.6.1 defines mappings from EFI memory types to MAIR attribute encodings for arm64. If the physical address has memory attributes defined by EFI memmap as EFI_MEMORY_[UC|WC|WT], return approprate page protection type. Otherwise,

[PATCH V8 2/5] x86: acpi: implement arch_apei_get_mem_attributes()

2015-07-24 Thread Jonathan (Zhixiong) Zhang
From: "Jonathan (Zhixiong) Zhang" ... to allow arch specific implementation of getting page protection type associated with a physical address. On x86, we currently have no way to lookup the EFI memory map attributes for a region in a consistent way because the memmap is discarded after

[PATCH V8 5/5] acpi, apei: use appropriate pgprot_t to map GHES memory

2015-07-24 Thread Jonathan (Zhixiong) Zhang
From: "Jonathan (Zhixiong) Zhang" With ACPI APEI firmware first handling, generic hardware error record is updated by firmware in GHES memory region. On an arm64 platform, firmware updates GHES memory region with uncached access attribute, and then Linux reads stale data from cache. GHES memory

[PATCH V8 3/5] arm64: mm: add PROT_DEVICE_nGnRnE and PROT_NORMAL_WT

2015-07-24 Thread Jonathan (Zhixiong) Zhang
From: "Jonathan (Zhixiong) Zhang" UEFI spec 2.5 section 2.3.6.1 defines that EFI_MEMORY_[UC|WC|WT|WB] are possible EFI memory types for AArch64. Each of those EFI memory types is mapped to a corresponding AArch64 memory type. So we need to define PROT_DEVICE_nGnRnE and PROT_NORMWL_WT

[PATCH V8 1/5] efi: x86: rearrange efi_mem_attributes()

2015-07-24 Thread Jonathan (Zhixiong) Zhang
From: "Jonathan (Zhixiong) Zhang" x86 and ia64 implement efi_mem_attributes() differently. This function needs to be available for other arch (such as arm64) as well, such as for the purpose of ACPI/APEI. ia64 efi does not setup memmap variable and does not set EFI_MEMMAP flag, so it needs to

[PATCH V8 0/5] map GHES memory region according to EFI memory map

2015-07-24 Thread Jonathan (Zhixiong) Zhang
_attribute(). The rational is explained in comment. 2. Rebased to arm64-upstream-14201 of arm64/master, next-20150724 of linux-next/master. V7: 1. Added PROT_DEVICE_nGnRnE and PROT_NORMAL_WT to support all possible UEFI memory types for arm64. V6: 1. Implemented arch_apei_get_mem_attributes()

Re: [PATCH 1/1] toshiba_acpi: Add set_fan_status function

2015-07-24 Thread Azael Avalos
Hi Darren, 2015-07-24 16:45 GMT-06:00 Darren Hart : > On Wed, Jul 22, 2015 at 07:37:48PM -0600, Azael Avalos wrote: >> This patch adds a new function named "set_fan_status" to complement >> its get* counterpart, as well as to avoid code duplication between >> "fan_proc_write" and "fan_store". > >

[PATCH] staging: unisys: avoid format string parsing

2015-07-24 Thread Kees Cook
This makes sure the kthread name can't be parsed as a format string. Signed-off-by: Kees Cook --- drivers/staging/unisys/visornic/visornic_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/unisys/visornic/visornic_main.c

[PATCH] ntb: avoid format string in dev_set_name

2015-07-24 Thread Kees Cook
Avoid any chance of format string expansion when calling dev_set_name. Signed-off-by: Kees Cook --- drivers/ntb/ntb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/ntb/ntb.c b/drivers/ntb/ntb.c index 23435f2a5486..2e2530743831 100644 --- a/drivers/ntb/ntb.c +++

[PATCH] iommu: avoid format string leaks into iommu_device_create

2015-07-24 Thread Kees Cook
This makes sure it won't be possible to accidentally leak format strings into iommu device names. Current name allocations are safe, but this makes the "%s" explicit. Signed-off-by: Kees Cook --- drivers/iommu/dmar.c| 2 +- drivers/iommu/intel-iommu.c | 2 +- 2 files changed, 2

Re: [PATCH 2/3] Docs: dt: Add PCI MSI map bindings

2015-07-24 Thread Chalamarla, Tirumalesh
looks good. possible to describe the chip we have. > On Jul 23, 2015, at 9:52 AM, Mark Rutland wrote: > > Currently msi-parent is used by a few bindings to describe the > relationship between a PCI root complex and a single MSI controller, but > this property does not have a generic binding

Re: [Xen-devel] [PATCHv2 10/10] xen/balloon: pre-allocate p2m entries for ballooned pages

2015-07-24 Thread Julien Grall
Hi David, On 24/07/2015 12:47, David Vrabel wrote: Pages returned by alloc_xenballooned_pages() will be used for grant mapping which will call set_phys_to_machine() (in PV guests). Ballooned pages are set as INVALID_P2M_ENTRY in the p2m and thus may be using the (shared) missing tables and a

[PATCH] clk_register_clkdev: handle callers needing format string

2015-07-24 Thread Kees Cook
Many callers either use NULL or const strings for the third argument of clk_register_clkdev. For those that do not, this is a risk for format strings being accidentally processed (for example in device names). This adds the missing "%s" arguments to make sure format strings will not leak into the

Re: [PATCH] kthread: Export kthread functions

2015-07-24 Thread Neil Horman
On Fri, Jul 24, 2015 at 06:45:20PM -0400, David Kershner wrote: > The s-Par visornic driver, currently in staging, processes a queue > being serviced by the an s-Par service partition. We can get a message > that something has happened with the Service Partition, when that > happens, we must not

Re: linux-next: build failure after merge of the akpm-current tree

2015-07-24 Thread Paul E. McKenney
On Fri, Jul 24, 2015 at 01:16:05PM -0700, Davidlohr Bueso wrote: > On Fri, 2015-07-24 at 15:33 +1000, Stephen Rothwell wrote: > > Hi Andrew, > > > > After merging the akpm-current tree, today's linux-next build (powerpc > > allnoconfig) failed like this: > > > > mm/built-in.o: In function

Re: [RFC v2 1/4] mm: make alloc_pages_exact_node pass __GFP_THISNODE

2015-07-24 Thread David Rientjes
On Fri, 24 Jul 2015, Vlastimil Babka wrote: > > I assume you looked at the collapse_huge_page() case and decided that it > > needs no modification since the gfp mask is used later for other calls? > > Yeah. Not that the memcg charge parts would seem to care about __GFP_THISNODE, > though. >

Re: [RFC v2 4/4] mm: fallback for offline nodes in alloc_pages_node

2015-07-24 Thread David Rientjes
On Fri, 24 Jul 2015, Vlastimil Babka wrote: > >>> diff --git a/include/linux/gfp.h b/include/linux/gfp.h > >>> index 531c72d..104a027 100644 > >>> --- a/include/linux/gfp.h > >>> +++ b/include/linux/gfp.h > >>> @@ -321,8 +321,12 @@ static inline struct page *alloc_pages_node(int nid, > >>> gfp_t

[PATCH] kthread: Export kthread functions

2015-07-24 Thread David Kershner
The s-Par visornic driver, currently in staging, processes a queue being serviced by the an s-Par service partition. We can get a message that something has happened with the Service Partition, when that happens, we must not access the channel until we get a message that the service partition is

Re: [PATCH v2] thermal: consistently use int for temperatures

2015-07-24 Thread Guenter Roeck
On 07/24/2015 03:11 PM, Pavel Machek wrote: On Fri 2015-07-24 06:59:26, Guenter Roeck wrote: On 07/23/2015 11:29 PM, Sascha Hauer wrote: On Thu, Jul 23, 2015 at 02:07:59PM +0200, Pavel Machek wrote: On Tue 2015-07-21 09:21:32, Sascha Hauer wrote: The thermal code uses int, long and unsigned

Re: [PATCH 1/1] toshiba_acpi: Add set_fan_status function

2015-07-24 Thread Darren Hart
On Wed, Jul 22, 2015 at 07:37:48PM -0600, Azael Avalos wrote: > This patch adds a new function named "set_fan_status" to complement > its get* counterpart, as well as to avoid code duplication between > "fan_proc_write" and "fan_store". It also appears to change the error codes returned via

  1   2   3   4   5   6   7   8   9   10   >