Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sync up with Linus #53

Merged
merged 160 commits into from
Mar 23, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
160 commits
Select commit Hold shift + click to select a range
b388e6a
UBI: fix missing brace control flow
computersforpeace Feb 23, 2015
5f027a3
dm thin: fix to consistently zero-fill reads to unprovisioned blocks
jthornber Feb 27, 2015
ab7c7bb
dm: hold suspend_lock while suspending device during device deletion
Feb 27, 2015
b735fed
dm snapshot: suspend origin when doing exception handover
Feb 26, 2015
09ee96b
dm snapshot: suspend merging snapshot when doing exception handover
Feb 26, 2015
e5db298
dm io: deal with wandering queue limits when handling REQ_DISCARD and…
djwong Feb 27, 2015
21647f7
phy: miphy28lp: Avoid calling of_get_child_count() multiple times
AxelLin Feb 24, 2015
5bd568f
phy: miphy365x: Avoid calling of_get_child_count() multiple times
AxelLin Feb 24, 2015
7a83b14
phy: armada375-usb2: Set drvdata for phy and use it
AxelLin Feb 25, 2015
991e45f
phy: xgene: Remove duplicate code to set ctx->dev
AxelLin Feb 25, 2015
235b633
phy: miphy28lp: Add missing .owner field in miphy28lp_ops
AxelLin Feb 25, 2015
cfd565d
phy: exynos-mipi-video: Fixup the test for state->regmap
AxelLin Feb 26, 2015
c312530
staging: vt6655: vnt_tx_packet fix dma_idx selection.
Feb 9, 2015
163fe30
staging: vt6656: vnt_rf_setpower: fix missing rate RATE_12M
Mar 7, 2015
40c8790
vt6655: RFbSetPower fix missing rate RATE_12M
Mar 7, 2015
1f51d58
vt6655: Fix late setting of byRFType.
Mar 7, 2015
7985239
usb: isp1760: fix possible deadlock in isp1760_udc_irq
sudeep-holla Mar 4, 2015
1c390eb
usb: musb: fix Kconfig regression
arndb Feb 27, 2015
80b4a0f
usb: isp1760: set IRQ flags properly
Mar 1, 2015
1998ada
usb: isp1760: add peripheral/device controller chip id
sudeep-holla Feb 26, 2015
8bf1268
ARM: dma-api: fix off-by-one error in __dma_supported()
Mar 10, 2015
6d021b7
ARM: dump pgd, pmd and pte states on unhandled data abort faults
Mar 10, 2015
509d612
usb: dwc2: host: fix dwc2 disconnect bug
Mar 6, 2015
d0f347d
usb: phy: am335x-control: check return value of bus_find_device
Feb 8, 2015
af69dec
phy: exynos-mipi-video: Use spin_lock to protct state->regmap rmw ope…
AxelLin Feb 27, 2015
d0167ad
Revert "xhci: Clear the host side toggle manually when endpoint is 's…
matnyman Mar 10, 2015
b2c08ba
Revert "pcmcia: add missing include for new pci resource handler"
gregkh Mar 11, 2015
05c0006
Revert "pcmcia: fix incorrect bracketing on a test"
gregkh Mar 11, 2015
3d7a827
Revert "pcmcia: add a new resource manager for non ISA systems"
gregkh Mar 11, 2015
2c24780
Revert "usb: gadget: zero: Add support for interrupt EP"
Mar 11, 2015
7fd6f64
serial: 8250_dw: Fix deadlock in LCR workaround
peterhurley Mar 11, 2015
0f9722e
phy: exynos-dp-video: Kill exynos_dp_video_phy_pwr_isol function
AxelLin Feb 27, 2015
1cbdfc4
phy: hix5hd2-sata: Check return value of platform_get_resource
AxelLin Mar 2, 2015
bd4abc2
phy: samsung-usb2: Remove NULL terminating entry from phys array
AxelLin Mar 3, 2015
a5e5d3c
phy: ti-pipe3: Simplify ti_pipe3_dpll_wait_lock implementation
AxelLin Mar 3, 2015
6b08e36
phy: rockchip-usb: Fixup rockchip_usb_phy_power_on failure path
AxelLin Mar 4, 2015
7814657
netfilter: Zero the tuple in nfnl_cthelper_parse_tuple()
Mar 12, 2015
bdf6c79
dmaengine: at_hdmac: Fix calculation of the residual bytes
Feb 23, 2015
d8bdff5
netfilter: Fix potential crash in nft_hash walker
herbertx Mar 12, 2015
2f1bce4
phy: Find the right match in devm_phy_destroy()
thierryreding Feb 25, 2015
ecd5fb0
phy: exynos5-usbdrd: Fix off-by-one valid value checking for args->ar…
AxelLin Feb 27, 2015
8f27f16
phy: twl4030-usb: Remove redundant assignment for twl->linkstat
AxelLin Mar 1, 2015
d8d5294
phy: miphy365x: Convert to devm_kcalloc and fix wrong sizeof
AxelLin Mar 5, 2015
018e6ff
phy: miphy28lp: Convert to devm_kcalloc and fix wrong sizof
AxelLin Mar 5, 2015
736b67a
phy: core: Fixup return value of phy_exit when !pm_runtime_enabled
AxelLin Mar 6, 2015
dd64ad3
phy: ti/omap: Fix modalias
AxelLin Mar 6, 2015
b1ff323
phy: omap-usb2: Fix missing clk_prepare call when using old dt name
AxelLin Mar 11, 2015
43b6887
cpuidle: mvebu: Fix the CPU PM notifier usage
gclement Feb 26, 2015
ce6031c
cpuidle: mvebu: Update cpuidle thresholds for Armada XP SOCs
aimxhaisse Feb 13, 2015
d220712
btrfs: fix sizeof format specifier in btrfs_check_super_valid()
Feb 14, 2015
b4924a0
Btrfs: catch transaction abortion after waiting for it
Mar 6, 2015
48da5f0
Btrfs: fix comp_oper to get right order
Mar 13, 2015
8461a3d
Btrfs: fix merge delalloc logic
Mar 13, 2015
6a41dd0
Btrfs: account for the correct number of extents for delalloc reserva…
Mar 13, 2015
ea526d1
Btrfs: fix ASSERT(list_empty(&cur_trans->dirty_bgs_list)
Mar 13, 2015
a01b860
Merge branch 'cpuidle/4.0-fixes' of http://git.linaro.org/people/dani…
rafaeljw Mar 13, 2015
d474a4d
powercap / RAPL: handle domains with different energy units
Mar 13, 2015
313e1a0
Merge tag 'fixes-for-v4.0-rc3' of git://git.kernel.org/pub/scm/linux/…
gregkh Mar 14, 2015
c526c21
Merge tag 'for-4.0-rc' of git://git.kernel.org/pub/scm/linux/kernel/g…
gregkh Mar 15, 2015
d20f780
usb: chipidea: otg: add a_alt_hnp_support response for B device
Mar 8, 2015
963ffa3
MAINTAINERS: add entry for USB OTG FSM
Feb 15, 2015
319c1d4
drm/i915: Ensure plane->state->fb stays in sync with plane->fb
Mar 12, 2015
855832e
dmaengine: imx-sdma: switch to dynamic context mode after script loaded
Feb 15, 2015
a104a45
dmaengine: dw: append MODULE_ALIAS for platform driver
andy-shev Mar 9, 2015
7cff4b1
kernfs: handle poll correctly on 'direct_read' files.
neilbrown Mar 15, 2015
d5e7caf
LZ4 : fix the data abort issue
tomyeon Mar 16, 2015
aaad2d8
drm/amdkfd: destroy mqd when destroying kernel queue
Mar 8, 2015
4fadf6b
drm/amdkfd: Fix SDMA queue init. in non-HWS mode
Mar 10, 2015
e405ca3
drm/radeon: Changing number of compute pipe lines
Mar 8, 2015
adc346b
drm/nouveau/fifo/nv04: remove the loop from the interrupt handler
Jan 27, 2015
404ba3f
drm/nouveau/gr/gf100: fix some accidental or'ing of buffer addresses
Jan 27, 2015
9fcaa14
drm/nouveau/device: post write to NV_PMC_BOOT_1 when flipping endian …
Feb 1, 2015
7e547ad
drm/nouveau/device/gm100: Basic GM206 bring up (as copy of GM204)
shuehner Feb 21, 2015
5a6f690
drm/nouveau/bios: fix i2c table parsing for dcb 4.1
shuehner Feb 22, 2015
59caeae
Merge branch 'linux-4.0' of git://anongit.freedesktop.org/git/nouveau…
airlied Mar 17, 2015
d6b6cb1
netfilter: nf_tables: allow to change chain policy without hook if it…
ummakynes Mar 17, 2015
dcdf7f6
Btrfs: prepare block group cache before writing
Mar 2, 2015
ba11721
Btrfs: account merges/splits properly
Mar 13, 2015
bcb7e44
Btrfs: just free dummy extent buffers
Mar 16, 2015
6a3891c
Btrfs: add sanity test for outstanding_extents accounting
Mar 16, 2015
e1cbbfa
Btrfs: fix outstanding_extents accounting in DIO
Mar 17, 2015
8860168
rtc: at91rm9200: double locking bug in at91_rtc_interrupt()
Mar 17, 2015
7f0801e
drm/i915: Make sure the primary plane is enabled before reading out t…
Feb 5, 2015
5c95ed4
ARM: 8310/1: l2c: Fix prefetch settings dt parsing
Mar 12, 2015
f2ca09f
ARM: 8311/1: Don't use is_module_addr in setting page attributes
labbott Mar 13, 2015
526299c
ARM: 8313/1: Use read_cpuid_ext() macro instead of inline asm
Mar 17, 2015
5fcc3c8
drm/exynos: remove unused files
Feb 18, 2015
aed45ab
drm/exynos: IS_ERR() vs NULL bug
Feb 20, 2015
995fdfb
drm/exynos: Check for NULL dereference of crtc
charleskeepax Feb 17, 2015
3da6acf
drm/exynos: fix typo config name correctly.
daeinki Mar 6, 2015
cdbfca8
drm/exynos: fix the initialization order in FIMD
Mar 12, 2015
e32643a
USB: ehci-atmel: rework clk handling
Mar 17, 2015
a239118
drm/radeon: drop ttm two ended allocation
alexdeucher Mar 17, 2015
bda13e3
uas: Add US_FL_NO_ATA_1X for Initio Corporation controllers / devices
jwrdegoede Mar 16, 2015
a886bd9
usb: common: otg-fsm: only signal connect after switching to peripheral
Mar 12, 2015
ea524c7
dmaengine: pl08x: Define capabilities for generic capabilities reporting
broonie Mar 17, 2015
31a55cf
Merge branch 'exynos-drm-fixes' of git://git.kernel.org/pub/scm/linux…
airlied Mar 19, 2015
4a87b99
Merge branch 'drm-fixes-4.0' of git://people.freedesktop.org/~agd5f/l…
airlied Mar 19, 2015
4017a7e
netfilter: restore rule tracing via nfnetlink_log
ummakynes Mar 2, 2015
d7c1460
of/irq: Fix of_irq_parse_one() returned error codes
Mar 17, 2015
5ca1b0d
of: unittest: Add option string test case with longer path
computersforpeace Mar 17, 2015
721a09e
of: handle both '/' and ':' in path strings
computersforpeace Mar 17, 2015
f64255b
Revert "of: Fix premature bootconsole disable with 'stdout-path'"
peterhurley Mar 17, 2015
133d558
Subject: nfsd: don't recursively call nfsd4_cb_layout_fail
Mar 5, 2015
5b0d4b5
sparc: perf: Remove redundant perf_pmu_{en|dis}able calls
Mar 19, 2015
d51291c
sparc: perf: Make counting mode actually work
Mar 19, 2015
b5aff55
sparc: perf: Add support M7 processor
Mar 19, 2015
31aaa98
sparc: Touch NMI watchdog when walking cpus and calling printk
Mar 19, 2015
4b36b68
target: Disallow changing of WRITE cache/FUA attrs after export
Feb 23, 2015
2a03ee8
Revert "iscsi-target: Avoid IN_LOGOUT failure case for iser-target"
Feb 26, 2015
f068fbc
iscsi-target: Avoid early conn_logout_comp for iser connections
Feb 23, 2015
75c3d0b
tcm_qla2xxx: Fix incorrect use of __transport_register_session
Mar 20, 2015
2f450cc
loop/usb/vhost-scsi/xen-scsiback: Fix use of __transport_register_ses…
Feb 12, 2015
7544e59
target: Fix reference leak in target_get_sess_cmd() error path
Feb 18, 2015
d556546
tcm_fc: missing curly braces in ft_invl_hw_context()
Feb 25, 2015
215a8fe
target/pscsi: Fix NULL pointer dereference in get_device_type
Feb 27, 2015
5f7da04
target: Fix virtual LUN=0 target_configure_device failure OOPs
Mar 5, 2015
9bc6548
target: do not reject FUA CDBs when write cache is enabled but emulat…
cvubrugier Mar 19, 2015
f42e2c2
Merge tag 'drm-amdkfd-fixes-2015-03-19' of git://people.freedesktop.o…
airlied Mar 20, 2015
8265d44
Merge tag 'drm-intel-fixes-2015-03-19' of git://anongit.freedesktop.o…
airlied Mar 20, 2015
3d8c6dc
netfilter: xt_TPROXY: fix invflags check in tproxy_tg6_check()
ummakynes Mar 20, 2015
9e8ce4b
Revert "x86/PCI: Refine the way to release PCI IRQ resources"
rafaeljw Mar 20, 2015
8e199df
ipv6: call ipv6_proxy_select_ident instead of ipv6_select_ident in ud…
qsn Mar 19, 2015
87f966d
net: ethernet: pcnet32: Setup the SRAM and NOUFLO on Am79C97{3, 5}
Mar 19, 2015
73ba57b
ipv6: fix backtracking for throw routes
Mar 19, 2015
130c93f
arm64: efi: don't restore TTBR0 if active_mm points at init_mm
wildea01 Mar 19, 2015
d22e153
tcp: fix tcp fin memory accounting
geauxbears Mar 19, 2015
435452a
be2net: Prevent VFs from enabling VLAN promiscuous mode
Mar 20, 2015
c8ba4ad
be2net: restrict MODIFY_EQ_DELAY cmd to a max of 8 EQs
Mar 20, 2015
25848c9
be2net: use PCI MMIO read instead of config read for errors
Mar 20, 2015
de58a6d
Merge branch 'be2net'
davem330 Mar 20, 2015
7132813
arm64: Honor __GFP_ZERO in dma allocations
Mar 19, 2015
91edd09
net: compat: Update get_compat_msghdr() to match copy_msghdr_from_use…
ctmarinas Mar 20, 2015
4de930e
net: validate the range we feed to iov_iter_init() in sys_sendto/sys_…
Mar 20, 2015
0c35bd4
md: fix problems with freeing private data after ->run failure.
neilbrown Mar 13, 2015
9c86286
Merge branches 'pm-cpuidle', 'powercap', 'irq-pm' and 'acpi-resources'
rafaeljw Mar 20, 2015
62a202d
Merge branch 'fixes' of git://ftp.arm.linux.org.uk/~rmk/linux-arm
torvalds Mar 21, 2015
60ed380
Merge tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/…
torvalds Mar 21, 2015
c6ef814
Merge tag 'upstream-4.0-rc5' of git://git.infradead.org/linux-ubifs
torvalds Mar 21, 2015
0d122f7
Merge branch 'for-4.0' of git://linux-nfs.org/~bfields/linux
torvalds Mar 21, 2015
521d474
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel…
torvalds Mar 21, 2015
da6b9a2
Merge tag 'dm-4.0-fixes' of git://git.kernel.org/pub/scm/linux/kernel…
torvalds Mar 21, 2015
e477f3e
Merge git://git.kernel.org/pub/scm/linux/kernel/git/nab/target-pending
torvalds Mar 21, 2015
bb8ef2f
Merge tag 'devicetree-fixes-for-4.0-part2' of git://git.kernel.org/pu…
torvalds Mar 21, 2015
97448d5
Merge git://people.freedesktop.org/~airlied/linux
torvalds Mar 21, 2015
3d7a6db
Merge tag 'pm+acpi-4.0-rc5' of git://git.kernel.org/pub/scm/linux/ker…
torvalds Mar 21, 2015
f897522
Merge branch 'fixes' of git://git.infradead.org/users/vkoul/slave-dma
torvalds Mar 21, 2015
f40bff4
cx82310_eth: wait for firmware to become ready
Mar 21, 2015
749177c
netfilter: nft_compat: set IP6T_F_PROTO flag if protocol is set
ummakynes Mar 21, 2015
cedd5f6
Merge tag 'usb-4.0-rc5' of git://git.kernel.org/pub/scm/linux/kernel/…
torvalds Mar 22, 2015
b2f45ee
Merge tag 'tty-4.0-rc5' of git://git.kernel.org/pub/scm/linux/kernel/…
torvalds Mar 22, 2015
704fa7f
Merge tag 'staging-4.0-rc5' of git://git.kernel.org/pub/scm/linux/ker…
torvalds Mar 22, 2015
b93dbee
Merge tag 'char-misc-4.0-rc5' of git://git.kernel.org/pub/scm/linux/k…
torvalds Mar 22, 2015
4541c22
Merge tag 'driver-core-4.0-rc5' of git://git.kernel.org/pub/scm/linux…
torvalds Mar 22, 2015
c0e41fa
Merge git://git.kernel.org/pub/scm/linux/kernel/git/pablo/nf
davem330 Mar 22, 2015
1b717b1
Merge tag 'md/4.0-rc4-fix' of git://neil.brown.name/md
torvalds Mar 22, 2015
bc465aa
Linux 4.0-rc5
torvalds Mar 22, 2015
2077cef
sparc64: Fix several bugs in memmove().
davem330 Mar 23, 2015
d504961
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc
torvalds Mar 23, 2015
90a5a89
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
torvalds Mar 23, 2015
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions MAINTAINERS
Original file line number Diff line number Diff line change
Expand Up @@ -10207,6 +10207,13 @@ S: Maintained
F: Documentation/usb/ohci.txt
F: drivers/usb/host/ohci*

USB OTG FSM (Finite State Machine)
M: Peter Chen <[email protected]>
T: git git://github.com/hzpeterchen/linux-usb.git
L: [email protected]
S: Maintained
F: drivers/usb/common/usb-otg-fsm.c

USB OVER IP DRIVER
M: Valentina Manea <[email protected]>
M: Shuah Khan <[email protected]>
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
VERSION = 4
PATCHLEVEL = 0
SUBLEVEL = 0
EXTRAVERSION = -rc4
EXTRAVERSION = -rc5
NAME = Hurr durr I'ma sheep

# *DOCUMENTATION*
Expand Down
5 changes: 1 addition & 4 deletions arch/arm/kernel/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -246,12 +246,9 @@ static int __get_cpu_architecture(void)
if (cpu_arch)
cpu_arch += CPU_ARCH_ARMv3;
} else if ((read_cpuid_id() & 0x000f0000) == 0x000f0000) {
unsigned int mmfr0;

/* Revised CPUID format. Read the Memory Model Feature
* Register 0 and check for VMSAv7 or PMSAv7 */
asm("mrc p15, 0, %0, c0, c1, 4"
: "=r" (mmfr0));
unsigned int mmfr0 = read_cpuid_ext(CPUID_EXT_MMFR0);
if ((mmfr0 & 0x0000000f) >= 0x00000003 ||
(mmfr0 & 0x000000f0) >= 0x00000030)
cpu_arch = CPU_ARCH_ARMv7;
Expand Down
33 changes: 16 additions & 17 deletions arch/arm/mm/cache-l2x0.c
Original file line number Diff line number Diff line change
Expand Up @@ -1131,23 +1131,22 @@ static void __init l2c310_of_parse(const struct device_node *np,
}

ret = l2x0_cache_size_of_parse(np, aux_val, aux_mask, &assoc, SZ_512K);
if (ret)
return;

switch (assoc) {
case 16:
*aux_val &= ~L2X0_AUX_CTRL_ASSOC_MASK;
*aux_val |= L310_AUX_CTRL_ASSOCIATIVITY_16;
*aux_mask &= ~L2X0_AUX_CTRL_ASSOC_MASK;
break;
case 8:
*aux_val &= ~L2X0_AUX_CTRL_ASSOC_MASK;
*aux_mask &= ~L2X0_AUX_CTRL_ASSOC_MASK;
break;
default:
pr_err("L2C-310 OF cache associativity %d invalid, only 8 or 16 permitted\n",
assoc);
break;
if (!ret) {
switch (assoc) {
case 16:
*aux_val &= ~L2X0_AUX_CTRL_ASSOC_MASK;
*aux_val |= L310_AUX_CTRL_ASSOCIATIVITY_16;
*aux_mask &= ~L2X0_AUX_CTRL_ASSOC_MASK;
break;
case 8:
*aux_val &= ~L2X0_AUX_CTRL_ASSOC_MASK;
*aux_mask &= ~L2X0_AUX_CTRL_ASSOC_MASK;
break;
default:
pr_err("L2C-310 OF cache associativity %d invalid, only 8 or 16 permitted\n",
assoc);
break;
}
}

prefetch = l2x0_saved_regs.prefetch_ctrl;
Expand Down
2 changes: 1 addition & 1 deletion arch/arm/mm/dma-mapping.c
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ static int __dma_supported(struct device *dev, u64 mask, bool warn)
*/
if (sizeof(mask) != sizeof(dma_addr_t) &&
mask > (dma_addr_t)~0 &&
dma_to_pfn(dev, ~0) < max_pfn) {
dma_to_pfn(dev, ~0) < max_pfn - 1) {
if (warn) {
dev_warn(dev, "Coherent DMA mask %#llx is larger than dma_addr_t allows\n",
mask);
Expand Down
1 change: 1 addition & 0 deletions arch/arm/mm/fault.c
Original file line number Diff line number Diff line change
Expand Up @@ -552,6 +552,7 @@ do_DataAbort(unsigned long addr, unsigned int fsr, struct pt_regs *regs)

pr_alert("Unhandled fault: %s (0x%03x) at 0x%08lx\n",
inf->name, fsr, addr);
show_pte(current->mm, addr);

info.si_signo = inf->sig;
info.si_errno = 0;
Expand Down
5 changes: 4 additions & 1 deletion arch/arm/mm/pageattr.c
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,10 @@ static int change_memory_common(unsigned long addr, int numpages,
WARN_ON_ONCE(1);
}

if (!is_module_address(start) || !is_module_address(end - 1))
if (start < MODULES_VADDR || start >= MODULES_END)
return -EINVAL;

if (end < MODULES_VADDR || start >= MODULES_END)
return -EINVAL;

data.set_mask = set_mask;
Expand Down
6 changes: 5 additions & 1 deletion arch/arm64/include/asm/proc-fns.h
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,11 @@ extern u64 cpu_do_resume(phys_addr_t ptr, u64 idmap_ttbr);

#include <asm/memory.h>

#define cpu_switch_mm(pgd,mm) cpu_do_switch_mm(virt_to_phys(pgd),mm)
#define cpu_switch_mm(pgd,mm) \
do { \
BUG_ON(pgd == swapper_pg_dir); \
cpu_do_switch_mm(virt_to_phys(pgd),mm); \
} while (0)

#define cpu_get_pgd() \
({ \
Expand Down
6 changes: 5 additions & 1 deletion arch/arm64/kernel/efi.c
Original file line number Diff line number Diff line change
Expand Up @@ -337,7 +337,11 @@ core_initcall(arm64_dmi_init);

static void efi_set_pgd(struct mm_struct *mm)
{
cpu_switch_mm(mm->pgd, mm);
if (mm == &init_mm)
cpu_set_reserved_ttbr0();
else
cpu_switch_mm(mm->pgd, mm);

flush_tlb_all();
if (icache_is_aivivt())
__flush_icache_all();
Expand Down
12 changes: 9 additions & 3 deletions arch/arm64/mm/dma-mapping.c
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ static int __init early_coherent_pool(char *p)
}
early_param("coherent_pool", early_coherent_pool);

static void *__alloc_from_pool(size_t size, struct page **ret_page)
static void *__alloc_from_pool(size_t size, struct page **ret_page, gfp_t flags)
{
unsigned long val;
void *ptr = NULL;
Expand All @@ -67,6 +67,8 @@ static void *__alloc_from_pool(size_t size, struct page **ret_page)

*ret_page = phys_to_page(phys);
ptr = (void *)val;
if (flags & __GFP_ZERO)
memset(ptr, 0, size);
}

return ptr;
Expand Down Expand Up @@ -101,6 +103,7 @@ static void *__dma_alloc_coherent(struct device *dev, size_t size,
flags |= GFP_DMA;
if (IS_ENABLED(CONFIG_DMA_CMA) && (flags & __GFP_WAIT)) {
struct page *page;
void *addr;

size = PAGE_ALIGN(size);
page = dma_alloc_from_contiguous(dev, size >> PAGE_SHIFT,
Expand All @@ -109,7 +112,10 @@ static void *__dma_alloc_coherent(struct device *dev, size_t size,
return NULL;

*dma_handle = phys_to_dma(dev, page_to_phys(page));
return page_address(page);
addr = page_address(page);
if (flags & __GFP_ZERO)
memset(addr, 0, size);
return addr;
} else {
return swiotlb_alloc_coherent(dev, size, dma_handle, flags);
}
Expand Down Expand Up @@ -146,7 +152,7 @@ static void *__dma_alloc(struct device *dev, size_t size,

if (!coherent && !(flags & __GFP_WAIT)) {
struct page *page = NULL;
void *addr = __alloc_from_pool(size, &page);
void *addr = __alloc_from_pool(size, &page, flags);

if (addr)
*dma_handle = phys_to_dma(dev, page_to_phys(page));
Expand Down
12 changes: 12 additions & 0 deletions arch/sparc/include/asm/hypervisor.h
Original file line number Diff line number Diff line change
Expand Up @@ -2957,6 +2957,17 @@ unsigned long sun4v_t5_set_perfreg(unsigned long reg_num,
unsigned long reg_val);
#endif


#define HV_FAST_M7_GET_PERFREG 0x43
#define HV_FAST_M7_SET_PERFREG 0x44

#ifndef __ASSEMBLY__
unsigned long sun4v_m7_get_perfreg(unsigned long reg_num,
unsigned long *reg_val);
unsigned long sun4v_m7_set_perfreg(unsigned long reg_num,
unsigned long reg_val);
#endif

/* Function numbers for HV_CORE_TRAP. */
#define HV_CORE_SET_VER 0x00
#define HV_CORE_PUTCHAR 0x01
Expand All @@ -2981,6 +2992,7 @@ unsigned long sun4v_t5_set_perfreg(unsigned long reg_num,
#define HV_GRP_SDIO 0x0108
#define HV_GRP_SDIO_ERR 0x0109
#define HV_GRP_REBOOT_DATA 0x0110
#define HV_GRP_M7_PERF 0x0114
#define HV_GRP_NIAG_PERF 0x0200
#define HV_GRP_FIRE_PERF 0x0201
#define HV_GRP_N2_CPU 0x0202
Expand Down
1 change: 1 addition & 0 deletions arch/sparc/kernel/hvapi.c
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ static struct api_info api_table[] = {
{ .group = HV_GRP_VT_CPU, },
{ .group = HV_GRP_T5_CPU, },
{ .group = HV_GRP_DIAG, .flags = FLAG_PRE_API },
{ .group = HV_GRP_M7_PERF, },
};

static DEFINE_SPINLOCK(hvapi_lock);
Expand Down
16 changes: 16 additions & 0 deletions arch/sparc/kernel/hvcalls.S
Original file line number Diff line number Diff line change
Expand Up @@ -837,3 +837,19 @@ ENTRY(sun4v_t5_set_perfreg)
retl
nop
ENDPROC(sun4v_t5_set_perfreg)

ENTRY(sun4v_m7_get_perfreg)
mov %o1, %o4
mov HV_FAST_M7_GET_PERFREG, %o5
ta HV_FAST_TRAP
stx %o1, [%o4]
retl
nop
ENDPROC(sun4v_m7_get_perfreg)

ENTRY(sun4v_m7_set_perfreg)
mov HV_FAST_M7_SET_PERFREG, %o5
ta HV_FAST_TRAP
retl
nop
ENDPROC(sun4v_m7_set_perfreg)
33 changes: 33 additions & 0 deletions arch/sparc/kernel/pcr.c
Original file line number Diff line number Diff line change
Expand Up @@ -217,6 +217,31 @@ static const struct pcr_ops n5_pcr_ops = {
.pcr_nmi_disable = PCR_N4_PICNPT,
};

static u64 m7_pcr_read(unsigned long reg_num)
{
unsigned long val;

(void) sun4v_m7_get_perfreg(reg_num, &val);

return val;
}

static void m7_pcr_write(unsigned long reg_num, u64 val)
{
(void) sun4v_m7_set_perfreg(reg_num, val);
}

static const struct pcr_ops m7_pcr_ops = {
.read_pcr = m7_pcr_read,
.write_pcr = m7_pcr_write,
.read_pic = n4_pic_read,
.write_pic = n4_pic_write,
.nmi_picl_value = n4_picl_value,
.pcr_nmi_enable = (PCR_N4_PICNPT | PCR_N4_STRACE |
PCR_N4_UTRACE | PCR_N4_TOE |
(26 << PCR_N4_SL_SHIFT)),
.pcr_nmi_disable = PCR_N4_PICNPT,
};

static unsigned long perf_hsvc_group;
static unsigned long perf_hsvc_major;
Expand Down Expand Up @@ -248,6 +273,10 @@ static int __init register_perf_hsvc(void)
perf_hsvc_group = HV_GRP_T5_CPU;
break;

case SUN4V_CHIP_SPARC_M7:
perf_hsvc_group = HV_GRP_M7_PERF;
break;

default:
return -ENODEV;
}
Expand Down Expand Up @@ -293,6 +322,10 @@ static int __init setup_sun4v_pcr_ops(void)
pcr_ops = &n5_pcr_ops;
break;

case SUN4V_CHIP_SPARC_M7:
pcr_ops = &m7_pcr_ops;
break;

default:
ret = -ENODEV;
break;
Expand Down
Loading