02 Sep, 2016
1 commit
-
The local end of each SMD channel is responsible for updating the tx
head and the rx tail, as such we should not touch the tx tail during a
reset.Reported-by: Jeremy McNicoll
Signed-off-by: Bjorn Andersson
Signed-off-by: Andy Gross
24 Aug, 2016
4 commits
-
By representing each edge as its own device the channels are no longer
tied to being parented by the same smd device and as such an edge can
live as children of e.g. remoteproc instances.Signed-off-by: Bjorn Andersson
Signed-off-by: Andy Gross -
The code exectued by the interrupt handler depends on the values parsed
after requesting the irq, just to be save we should therefor move the
request_irq() call to be done after parsing the properties.Signed-off-by: Bjorn Andersson
Signed-off-by: Andy Gross -
Multi-channel clients split between several drivers need a way to close
individual channels, as these drivers might be removed individually.
With this in place the responsibility of closing additionally opened
channels to the client as well only concerning smd about the primary
channel.With this approach we will only trigger removal of SMD devices based on
the state of the primary channel, however we get in sync with how rpmsg
works.Signed-off-by: Bjorn Andersson
Signed-off-by: Andy Gross -
If we fail to get the hwspinlock due to probe defer, we shouldn't
print an error message. Just be silent in this case.Cc: Bjorn Andersson
Signed-off-by: Stephen Boyd
Reviewed-by: Bjorn Andersson
Signed-off-by: Andy Gross
25 Jun, 2016
4 commits
-
Update the property names to match device tree bindings, the correct
values should be qcom,smem-states and qcom,smem-state-names.Also update the #qcom,smem-state-cells for consistency, before we merge
any users of these properties.Signed-off-by: Bjorn Andersson
Acked-by: Rob Herring
Signed-off-by: Andy Gross -
SMEM is now mapped write-combine and we can use memcpy to access the
name of the entires.Signed-off-by: Bjorn Andersson
Signed-off-by: Andy Gross -
The valid_entries index should not be incremented until after we have
acquired the pointer to the value, or we will read and write data one
item off.Fixes: 50e99641413e ("soc: qcom: smp2p: Qualcomm Shared Memory Point to Point")
Cc: stable@vger.kernel.org
Signed-off-by: Bjorn Andersson
Signed-off-by: Andy Gross -
We need the signal from wcnss_ctrl indicating that the firmware is up
and running before we can communicate with the other components of the
chip. So make these other components children of the wcnss_ctrl device,
so they can be probed in order.The process seems to take between 1/2-5 seconds, so this is done in a
worker, instead of holding up the probe.Signed-off-by: Bjorn Andersson
Signed-off-by: Andy Gross
18 May, 2016
1 commit
-
Pull networking updates from David Miller:
"Highlights:1) Support SPI based w5100 devices, from Akinobu Mita.
2) Partial Segmentation Offload, from Alexander Duyck.
3) Add GMAC4 support to stmmac driver, from Alexandre TORGUE.
4) Allow cls_flower stats offload, from Amir Vadai.
5) Implement bpf blinding, from Daniel Borkmann.
6) Optimize _ASYNC_ bit twiddling on sockets, unless the socket is
actually using FASYNC these atomics are superfluous. From Eric
Dumazet.7) Run TCP more preemptibly, also from Eric Dumazet.
8) Support LED blinking, EEPROM dumps, and rxvlan offloading in mlx5e
driver, from Gal Pressman.9) Allow creating ppp devices via rtnetlink, from Guillaume Nault.
10) Improve BPF usage documentation, from Jesper Dangaard Brouer.
11) Support tunneling offloads in qed, from Manish Chopra.
12) aRFS offloading in mlx5e, from Maor Gottlieb.
13) Add RFS and RPS support to SCTP protocol, from Marcelo Ricardo
Leitner.14) Add MSG_EOR support to TCP, this allows controlling packet
coalescing on application record boundaries for more accurate
socket timestamp sampling. From Martin KaFai Lau.15) Fix alignment of 64-bit netlink attributes across the board, from
Nicolas Dichtel.16) Per-vlan stats in bridging, from Nikolay Aleksandrov.
17) Several conversions of drivers to ethtool ksettings, from Philippe
Reynes.18) Checksum neutral ILA in ipv6, from Tom Herbert.
19) Factorize all of the various marvell dsa drivers into one, from
Vivien Didelot20) Add VF support to qed driver, from Yuval Mintz"
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next: (1649 commits)
Revert "phy dp83867: Fix compilation with CONFIG_OF_MDIO=m"
Revert "phy dp83867: Make rgmii parameters optional"
r8169: default to 64-bit DMA on recent PCIe chips
phy dp83867: Make rgmii parameters optional
phy dp83867: Fix compilation with CONFIG_OF_MDIO=m
bpf: arm64: remove callee-save registers use for tmp registers
asix: Fix offset calculation in asix_rx_fixup() causing slow transmissions
switchdev: pass pointer to fib_info instead of copy
net_sched: close another race condition in tcf_mirred_release()
tipc: fix nametable publication field in nl compat
drivers: net: Don't print unpopulated net_device name
qed: add support for dcbx.
ravb: Add missing free_irq() calls to ravb_close()
qed: Remove a stray tab
net: ethernet: fec-mpc52xx: use phy_ethtool_{get|set}_link_ksettings
net: ethernet: fec-mpc52xx: use phydev from struct net_device
bpf, doc: fix typo on bpf_asm descriptions
stmmac: hardware TX COE doesn't work when force_thresh_dma_mode is set
net: ethernet: fs-enet: use phy_ethtool_{get|set}_link_ksettings
net: ethernet: fs-enet: use phydev from struct net_device
...
20 Apr, 2016
3 commits
-
The qcom_cpuidle_ops structures is not over-written, so add "const"
qualifier and replace __initdata with __initconst.Signed-off-by: Jisheng Zhang
Signed-off-by: Daniel Lezcano
Acked-by: Andy Gross -
By passing the smd channel reference to the callback, rather than the
smd device, we can open additional smd channels from sub-devices of smd
devices.Also updates the two smd clients today found in mainline.
Signed-off-by: Bjorn Andersson
Signed-off-by: Andy Gross -
Mapping the SMEM region as write combine makes the contiguous writes
in SMD perform better and also allows us to do unaligned read and writes
on ARM64.Signed-off-by: Bjorn Andersson
Reviewed-by: Andy Gross
Signed-off-by: Andy Gross
31 Mar, 2016
6 commits
-
With the qcom_smd_open_channel() API we allow SMD devices to open
additional SMD channels, to allow implementation of multi-channel SMD
devices - like Bluetooth.Channels are opened from the same edge as the calling SMD device is tied
to.Signed-off-by: Bjorn Andersson
Signed-off-by: Bjorn Andersson
Signed-off-by: Andy Gross -
This patch allows chaining additional channels to a SMD device, enabling
implementation of multi-channel SMD devies - like Bluetooth.Signed-off-by: Bjorn Andersson
Signed-off-by: Bjorn Andersson
Signed-off-by: Andy Gross -
Refactor opening and closing of channels into two separate functions
instead of open coding this in the various places.Signed-off-by: Bjorn Andersson
Signed-off-by: Bjorn Andersson
Signed-off-by: Andy Gross -
Split the two steps of channel discovery and state change handling into
two different workers. This allows for new channels to be found while
we're are probing, which is required as we introduce multi-channel
support.Signed-off-by: Bjorn Andersson
Signed-off-by: Bjorn Andersson
Signed-off-by: Andy Gross -
Introduce a setter for the callback function pointer to clarify the
locking around the operation and to reduce some duplication.Signed-off-by: Bjorn Andersson
Signed-off-by: Bjorn Andersson
Signed-off-by: Andy Gross -
SPM driver provides cpuidle support on some QC SoC's. The functionality
is non-modular and there is no need for module support. Convert module
platform init to builtin platform driver init. The driver functionality
is not affected by this change.Cc: Paul Gortmaker
Signed-off-by: Lina Iyer
Acked-by: Daniel Lezcano
Signed-off-by: Andy Gross
23 Jan, 2016
1 commit
-
Pull ARM SoC fixes from Olof Johansson:
"A few fixes for fallout that we didn't catch in time in -next, or
smaller warning fixes that have been discovered since"* tag 'armsoc-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc:
soc: qcom/spm: shut up uninitialized variable warning
ARM: realview: fix device tree build
ARM: debug-ll: fix BCM63xx entry for multiplatform
ARM: dts: armadillo800eva Correct extal1 frequency to 24 MHz
22 Jan, 2016
2 commits
-
gcc warns about the 'found' variable possibly being used uninitialized:
drivers/soc/qcom/spm.c: In function 'spm_dev_probe':
drivers/soc/qcom/spm.c:305:5: error: 'found' may be used uninitialized in this function [-Werror=maybe-uninitialized]However, the code is correct because we know that there is
always at least one online CPU. This initializes the 'found'
variable to zero before the loop so the compiler knows
it does not have to warn about it.Signed-off-by: Arnd Bergmann
-
Merge third patch-bomb from Andrew Morton:
"I'm pretty much done for -rc1 now:- the rest of MM, basically
- lib/ updates
- checkpatch, epoll, hfs, fatfs, ptrace, coredump, exit
- cpu_mask simplifications
- kexec, rapidio, MAINTAINERS etc, etc.
- more dma-mapping cleanups/simplifications from hch"
* emailed patches from Andrew Morton : (109 commits)
MAINTAINERS: add/fix git URLs for various subsystems
mm: memcontrol: add "sock" to cgroup2 memory.stat
mm: memcontrol: basic memory statistics in cgroup2 memory controller
mm: memcontrol: do not uncharge old page in page cache replacement
Documentation: cgroup: add memory.swap.{current,max} description
mm: free swap cache aggressively if memcg swap is full
mm: vmscan: do not scan anon pages if memcg swap limit is hit
swap.h: move memcg related stuff to the end of the file
mm: memcontrol: replace mem_cgroup_lruvec_online with mem_cgroup_online
mm: vmscan: pass memcg to get_scan_count()
mm: memcontrol: charge swap to cgroup2
mm: memcontrol: clean up alloc, online, offline, free functions
mm: memcontrol: flatten struct cg_proto
mm: memcontrol: rein in the CONFIG space madness
net: drop tcp_memcontrol.c
mm: memcontrol: introduce CONFIG_MEMCG_LEGACY_KMEM
mm: memcontrol: allow to disable kmem accounting for cgroup2
mm: memcontrol: account "kmem" consumers in cgroup2 memory controller
mm: memcontrol: move kmem accounting code to CONFIG_MEMCG
mm: memcontrol: separate kmem code from legacy tcp accounting code
...
21 Jan, 2016
2 commits
-
Pull ARM SoC driver updates from Olof Johansson:
"Driver updates for ARM SoCs. Some for SoC-family code under
drivers/soc, but also some other driver updates that don't belong
anywhere else. We also bring in the drivers/reset code through
arm-soc.Some of the larger updates:
- Qualcomm support for SMEM, SMSM, SMP2P. All used to communicate
with other parts of the chip/board on these platforms, all
proprietary protocols that don't fit into other subsystems and live
in drivers/soc for now.- System bus driver for UniPhier
- Driver for the TI Wakeup M3 IPC device
- Power management for Raspberry PI
+ Again a bunch of other smaller updates and patches"
* tag 'armsoc-drivers' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (38 commits)
bus: uniphier: allow only built-in driver
ARM: bcm2835: clarify RASPBERRYPI_FIRMWARE dependency
MAINTAINERS: Drop Kumar Gala from QCOM
bus: uniphier-system-bus: add UniPhier System Bus driver
ARM: bcm2835: add rpi power domain driver
dt-bindings: add rpi power domain driver bindings
ARM: bcm2835: Define two new packets from the latest firmware.
drivers/soc: make mediatek/mtk-scpsys.c explicitly non-modular
soc: mediatek: SCPSYS: Add regulator support
MAINTAINERS: Change QCOM entries
soc: qcom: smd-rpm: Add existing platform support
memory/tegra: Add number of TLB lines for Tegra124
reset: hi6220: fix modular build
soc: qcom: Introduce WCNSS_CTRL SMD client
ARM: qcom: select ARM_CPU_SUSPEND for power management
MAINTAINERS: Add rules for Qualcomm dts files
soc: qcom: enable smsm/smp2p modular build
serial: msm_serial: Make config tristate
soc: qcom: smp2p: Qualcomm Shared Memory Point to Point
soc: qcom: smsm: Add driver for Qualcomm SMSM
... -
Now that we have a generic library function for this, replace the
open-coded instance.Signed-off-by: Stephen Boyd
Reviewed-by: Bjorn Andersson
Cc:
Cc: David Howells
Cc: Hauke Mehrtens
Cc: Paul Walmsley
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
22 Dec, 2015
1 commit
-
The suspend() hook in the cpuidle_ops struct is always called on
the cpu entering idle, which means that the cpu parameter passed
to the suspend hook always corresponds to the local cpu, making
it somewhat redundant.This patch removes the logical cpu parameter from the ARM
cpuidle_ops.suspend hook and updates all the existing kernel
implementations to reflect this change.Signed-off-by: Lorenzo Pieralisi
Acked-by: Daniel Lezcano
Reviewed-by: Lina Iyer
Tested-by: Lina Iyer
Tested-by: Jisheng Zhang [psci]
Cc: Lina Iyer
Cc: Daniel Lezcano
Signed-off-by: Russell King
15 Dec, 2015
1 commit
-
This patch adds support for all current Qualcomm platforms which utilize
RPM over SMD. This includes both MSM8916 and APQ8084.Reviewed-by: Bjorn Andersson
Signed-off-by: Andy Gross
09 Dec, 2015
6 commits
-
The WCNSS_CTRL SMD client is used for among other things upload nv
firmware to a newly booted WCNSS chip.Signed-off-by: Bjorn Andersson
Signed-off-by: Andy Gross -
The qcom spm driver uses cpu_resume_arm(), which is not included
in the kernel in all configurations:drivers/built-in.o: In function `qcom_cpu_spc':
:(.text+0xbc022): undefined reference to `cpu_suspend'
drivers/built-in.o: In function `qcom_cpuidle_init':
:(.init.text+0x610c): undefined reference to `cpu_resume_arm'This adds a 'select' Kconfig statement to ensure it's always
enabled.Signed-off-by: Arnd Bergmann
Reviewed-by: Stephen Boyd
Signed-off-by: Andy Gross -
The newly added smp2p and smsm drivers cannot be loadable modules
but depend on smem, which can be, and that causes a link error:drivers/built-in.o: In function `qcom_smp2p_intr':
:(.text+0xa6e68): undefined reference to `qcom_smem_get'
drivers/built-in.o: In function `qcom_smp2p_probe':
:(.text+0xa7320): undefined reference to `qcom_smem_alloc'
:(.text+0xa736c): undefined reference to `qcom_smem_get'
drivers/built-in.o: In function `qcom_smsm_probe':
:(.text+0xa7b34): undefined reference to `qcom_smem_get'This marks all the drivers as 'tristate' to make the Kconfig
dependency resolution work properly.Signed-off-by: Arnd Bergmann
Fixes: dbb04bd7122f ("soc: qcom: smp2p: Qualcomm Shared Memory Point to Point")
Fixes: d7387fc6add4 ("soc: qcom: smsm: Add driver for Qualcomm SMSM")
Signed-off-by: Andy Gross -
Introduce the Qualcomm Shard Memory Point to Point driver.
Signed-off-by: Bjorn Andersson
Signed-off-by: Andy Gross -
This driver exposed the Qualcomm Shared Memory State Machine bits.
Signed-off-by: Bjorn Andersson
Signed-off-by: Andy Gross -
This implements a common API for handling and exposing SMP2P and SMSM
state information.Signed-off-by: Bjorn Andersson
Signed-off-by: Andy Gross
31 Oct, 2015
1 commit
-
With the removal of VLAIS the size was incorrectly changed to only cover
the headers of the packet, resulting in "empty" requests being sent to
the RPM. Correct this so the entire message is transfered.Fixes: 50e1b29b4438 ("soc: qcom: smd: Remove use of VLAIS")
Signed-off-by: Bjorn Andersson
Reviewed-by: Stephen Boyd
Signed-off-by: Andy Gross
Signed-off-by: Olof Johansson
16 Oct, 2015
1 commit
-
This fixes a build error when smem is enabled without hwspinlock:
drivers/built-in.o: In function `qcom_smem_alloc':
rockchip-efuse.c:(.text+0x7a3e4): undefined reference to `__hwspin_lock_timeout'
rockchip-efuse.c:(.text+0x7a568): undefined reference to `__hwspin_unlock'
drivers/built-in.o: In function `qcom_smem_remove':
rockchip-efuse.c:(.text+0x7a5cc): undefined reference to `hwspin_lock_free'
drivers/built-in.o: In function `qcom_smem_probe':
rockchip-efuse.c:(.text+0x7a960): undefined reference to `hwspin_lock_request_specific'
rockchip-efuse.c:(.text+0x7a988): undefined reference to `of_hwspin_lock_get_id'
drivers/built-in.o: In function `qcom_smem_get':
rockchip-efuse.c:(.text+0x7aa24): undefined reference to `__hwspin_lock_timeout'
rockchip-efuse.c:(.text+0x7aafc): undefined reference to `__hwspin_unlock'Signed-off-by: Arnd Bergmann
15 Oct, 2015
6 commits
-
SMEM is a software construct built on top of a DDR reserved region
and sometimes a device memory region called RPM message ram. Having
the RPM message ram in the smem DT node's reg property leads to the
smem node being located in different places depending on if the
message ram is being used or not. Let's add a qcom specific
property, qcom,rpm-msg-ram, and point to the device memory from
the SMEM node via a phandle. As SMEM is a software construct, it
really needs to reside at the root of the DT regardless of whether
it's using the message ram or not.Cc: Bjorn Andersson
Signed-off-by: Stephen Boyd
Signed-off-by: Andy Gross -
The BIT() was incorrectly inherited from family A and should not be used
on family B where the state is denoted by an enum.Reported-by: Georgi Djakov
Signed-off-by: Bjorn Andersson
Tested-by: Georgi Djakov
Signed-off-by: Andy Gross -
Device node iterators perform an of_node_put on each iteration, so putting
an of_node_put before a continue results in a double put.A simplified version of the semantic match that finds this problem is as
follows (http://coccinelle.lip6.fr)://
@@
expression root,e;
local idexpression child;
iterator i;
@@i(..., child, ...) {
... when != of_node_get(child)
* of_node_put(child);
...
* continue;
}
//Signed-off-by: Julia Lawall
Signed-off-by: Andy Gross -
Update the SMEM items for the second set of SMD channels, as these where
incorrect.Signed-off-by: Bjorn Andersson
Signed-off-by: Andy Gross -
Attempting to find room for a packet that's bigger than the fifo will
never succeed and the calling process will be sleeping forever in the
loop, waiting for enough room. So fail early instead.Reported-by: Courtney Cavin
Signed-off-by: Bjorn Andersson
Reviewed-by: Andy Gross
Signed-off-by: Andy Gross -
The smd structures are always in little endian, but the smd
driver is not capable of being used on big endian CPUs. Annotate
the little endian data members and update the code to do the
proper byte swapping.Cc: Bjorn Andersson
Signed-off-by: Stephen Boyd
Signed-off-by: Andy Gross