Age | Commit message (Collapse) | Author |
|
|
|
scpi_send_message is broken for a least two reasons.
1. The driver sets tx_block on the mailbox client and expects mbox_send_message
to block until the message is sent, however this isn't the case. Whether by
design or in error, mbox_send_message waits for tx_complete which will be
signalled when any message is transmitted, not the one just queued. So in the
case where two threads send messages concurrently, one thread may see the signal
from the other's message completing, whilst it's message is still in the queue.
2. The second flaw is that even if the mailbox framework was waiting for the
correct message signal the driver has set a timeout (mailbox client tx_tout)
which means the wait for that signal may be aborted whilst the message is still
in the queue for sending.
Both the above mean that when mbox_send_message returns the message may still be
pending transmission so we cannot safely do anything with its resources. The
current code however goes on to free the message with put_scpi_xfer resulting
in all sorts of bugs.
To fix this, we add code to do a proper wait for the message to complete and
if a timeout occurs BUG because we don't have any way to cancel messages in the
queue.
Signed-off-by: Jon Medhurst <tixy@linaro.org>
|
|
Conflicts:
arch/arm64/boot/dts/arm/juno-base.dtsi
linaro/configs/vexpress64.conf
|
|
Conflicts:
linaro/configs/vexpress64.conf
|
|
Conflicts:
arch/arm64/boot/dts/arm/Makefile
|
|
|
|
|
|
|
|
|
|
This is the same as r1 except that the A57 CPUs have been replaced by
A72s
Signed-off-by: Jon Medhurst <tixy@linaro.org>
|
|
Signed-off-by: Jon Medhurst <tixy@linaro.org>
|
|
The pci-generic-host controller is designed for firmware-initialised
systems, such as virtual machines. On juno-r1 we expect uefi to
initialise the host controller, so this driver is sufficient.
Signed-off-by: James Morse <james.morse@arm.com>
Signed-off-by: Jon Medhurst <tixy@linaro.org>
|
|
Signed-off-by: Liviu Dudau <Liviu.Dudau@arm.com>
Signed-off-by: Jon Medhurst <tixy@linaro.org>
|
|
For designs where EEPROMs are not connected to PCI Yukon2
chips we need to get the MAC address from the firmware.
Add a module parameter called 'mac_address' for this. It
will be used if no DT node can be found and the B2_MAC
register holds an invalid value.
Signed-off-by: Liviu Dudau <Liviu.Dudau@arm.com>
Signed-off-by: Jon Medhurst <tixy@linaro.org>
|
|
|
|
merge-linux-linaro-core-tracking
|
|
merge-linux-linaro-core-tracking
|
|
|
|
On building for Linux 4.3 we get errors like
drivers/gpu/arm/midgard/mali_kbase_gpu_memory_debugfs.c: In function 'kbasep_gpu_memory_seq_show':
drivers/gpu/arm/midgard/mali_kbase_gpu_memory_debugfs.c:46:7: error: void value not ignored as it ought to be
ret = seq_printf(sfile, "%-16s %10u\n",
^
so don't set 'ret'.
Signed-off-by: Jon Medhurst <tixy@linaro.org>
|
|
Signed-off-by: Jon Medhurst <tixy@linaro.org>
|
|
Signed-off-by: Jon Medhurst <tixy@linaro.org>
|
|
The Android gralloc for Juno expects an ION driver and as we don't have
a custom one we need this dummy one. Which begs the question, what is its
purpose and is it actually used for anything...?
Signed-off-by: Jon Medhurst <tixy@linaro.org>
|
|
Add configuration options to have the Mali GPU driver
built-in with Gator enabled.
Signed-off-by: Guillaume Tucker <guillaume.tucker@arm.com>
|
|
Setting up the OPPs via a module relies on the module being loaded at
the right time. For Juno that means that it has to be loaded after the
SCPI clocks are loaded but before the core mali driver. Getting that
ordering right is quite a pain and now that the SCPI is a platform
driver, using module_init is a guarantee for failure, as it's always
going to happen before any platform driver is loaded.
Instead, make setting up the opps a function that the driver
provides as a weak, dummy function that can be overridden by platforms
providing a strong function if they need to set up OPPs.
Signed-off-by: Javi Merino <javi.merino@arm.com>
Signed-off-by: Jon Medhurst <tixy@linaro.org>
|
|
Fix juno_mali_opp.c for the LSK 3.18 kernel. This still needs to be
called at the right point in time, that is to say after SCPI has been
initialised and before the Mali GPU driver gets initialised.
[Commit message wording by Guillaume Tucker <guillaume.tucker@arm.com>]
Signed-off-by: Jon Medhurst <tixy@linaro.org>
|
|
Fix juno_soc/Kbuild for both built-in and module
mali_kbase.ko configurations. The juno_mali_opp.ko
needs to be inserted manually first.
Signed-off-by: Guillaume Tucker <guillaume.tucker@arm.com>
|
|
This is now done in the simple_ondemand devfreq governor.
Signed-off-by: Javi Merino <javi.merino@arm.com>
Signed-off-by: Jon Medhurst <tixy@linaro.org>
|
|
Add drivers/gpu/arm/midgard and drivers/base/ump to
top-level Kconfig and Kbuild files.
Signed-off-by: Guillaume Tucker <guillaume.tucker@arm.com>
|
|
Contents extracted from TX041-SW-99002-r8p0-02rel0.tgz
downloaded from malideveloper.arm.com.
Signed-off-by: Jon Medhurst <tixy@linaro.org>
|
|
NOT intended for new Android devices - this commit is unnecessary
for a target device that does not have a previous M variant.
DO NOT upstream. Android only.
Motivation:
This commit mitigates a mismatch between selinux kernel and
selinux userspace. The selinux ioctl white-listing binary policy
format that was accepted into Android M differs slightly from what
was later accepted into the upstream kernel. This leaves Android
master branch kernels incompatible with Android M releases. This
patch restores backwards compatibility. This is important because:
1. kernels may be updated on a different cycle than the rest of the
OS e.g. security patching.
2. Android M bringup may still be ongoing for some devices. The
same kernel should work for both M and master.
Backwards compatibility is achieved by checking for an Android M
policy characteristic during initial policy read and converting to
upstream policy format. The inverse conversion is done for policy
write as required for CTS testing.
Bug: 22846070
Change-Id: I2f1ee2eee402f37cf3c9df9f9e03c1b9ddec1929
Signed-off-by: Jeff Vander Stoep <jeffv@google.com>
|
|
Change-Id: I520c50f919ac569f537bb445b5e4cb758d55ba8e
Signed-off-by: Sami Tolvanen <samitolvanen@google.com>
|
|
Bug: 24047224
Signed-off-by: Daniel Cashman <dcashman@google.com>
Change-Id: Ie4b6d175f636a8ee4b25cdc0a0407d440278ff63
[AmitP: cherry-picked from aosp/android-3.18,
bc8eb3ef2068 "arm: mm: support ARCH_MMAP_RND_BITS."
and resolved conflict by refactoring changes according
to upstream commit fbbc400f3924 "arm: factor out mmap
ASLR into mmap_rnd".]
Signed-off-by: Amit Pundir <amit.pundir@linaro.org>
Conflicts:
arch/arm/mm/mmap.c
|
|
ASLR currently only uses 8 bits to generate the random offset for the
mmap base address on 32 bit architectures. This value was chosen to
prevent a poorly chosen value from dividing the address space in such
a way as to prevent large allocations. This may not be an issue on all
platforms. Allow the specification of a minimum number of bits so that
platforms desiring greater ASLR protection may determine where to place
the trade-off.
BUG=24047224
Signed-off-by: Daniel Cashman <dcashman@google.com>
Change-Id: I0aa8f1e416fec848b6817ab861610d8f0eb3beb8
[AmitP: cherry-picked and resolved conflict by picking changes
from both upstream and aosp.]
Signed-off-by: Amit Pundir <amit.pundir@linaro.org>
Conflicts:
kernel/sysctl.c
|
|
c7c3ec4903d32c60423ee013d96e94602f66042c cherry-picked the
tcp_nuke_addr ioctl, but omitted a check that ensures that a
socket is an IPv6 socket. This makes it so that if we issue a
SIOCKILLADDR on ::, it kills IPv4 sockets as well.
This is because every IPv4 socket has an IPv6 source address
(sk_v6_rcv_saddr) of ::. Thus, when we iterate over an IPv4
socket, and compare the source address of the socket to the
source address in the ioctl, it matches the :: that was passed
in, and we kill the socket.
Change-Id: I736431a898e6ec91536536d352936a210aa10100
|
|
Checking if the uid_entry->uid matches the uid intended to be removed will
prevent deleting unwanted uid_entry.
Type cast the key for the hashtable to the same size, as when they were
inserted. This will make sure that we can find the uid_entry we want.
Bug: 25195548
Change-Id: I567942123cfb20e4b61ad624da19ec4cc84642c1
Signed-off: Ruchi kandoi <kandoiruchi@google.com>
|
|
If a /d/binder/proc/[pid] entry is kept open after linux has
torn down the associated process, binder_proc_show can deference
an invalid binder_proc that has been stashed in the debugfs
inode. Validate that the binder_proc ptr passed into binder_proc_show
has not been freed by looking for it within the global process list
whilst the global lock is held. If the ptr is not valid, print nothing.
Bug 19587483
Change-Id: Ice878c171db51ef9a4879c2f9299a2deb873d255
Signed-off-by: Riley Andrews <riandrews@android.com>
[AmitP: cherry-picked and resolved conflict by moving changes from
drivers/staging/android/binder.c to drivers/android/binder.c]
Signed-off-by: Amit Pundir <amit.pundir@linaro.org>
Conflicts:
drivers/staging/android/binder.c
|
|
ION_POOL_CACHE_POLICY uses x86 specific commands.
Only allow it to be used for x86.
Signed-off-by: Daniel Rosenberg <drosen@google.com>
Change-Id: Ic66e175fa41486b0b5f77872f2193add77cbe66f
(cherry picked from commit 43f4056cbec017c4414d74b032e9c14e009eabb0)
|
|
Added return address to show caller function in /proc/vmallocinfo
Change-Id: Ieb0bbf6ec82b561cea6ff18f0516744050dfc269
[AmitP: cherry-picked and resolved conflict by refactoring changes
from android-3.18 commit 497ead03dee0 "arm64: pass return address to
dma_common_contiguous_remap", based on changes from upstream commit
97942c2862d7 "arm64: dma-mapping: Simplify pgprot handling".]
Signed-off-by: Amit Pundir <amit.pundir@linaro.org>
Conflicts:
arch/arm64/mm/dma-mapping.c
|
|
Heavily based on earlier version of HDLCD driver by
Liviu Dudau <Liviu.Dudau@arm.com>
Signed-off-by: Jon Medhurst <tixy@linaro.org>
|
|
This is what Android expects so it can do double buffering.
Signed-off-by: Jon Medhurst <tixy@linaro.org>
|
|
Because we need to modify it to get Android and Mali working
Signed-off-by: Jon Medhurst <tixy@linaro.org>
|
|
Rather than a custom implementation. This is possible since
commit 1d1ddf67dc3b ("arm64: dma-mapping: implement dma_get_sgtable()")
Signed-off-by: Jon Medhurst <tixy@linaro.org>
|
|
ion_buffer_create() will allocate a buffer and then create a DMA
mapping for it, but it forgot to set the length of the page entries.
Signed-off-by: Liviu Dudau <Liviu.Dudau@arm.com>
Signed-off-by: Jon Medhurst <tixy@linaro.org>
|
|
Signed-off-by: Jon Medhurst <tixy@linaro.org>
|
|
If hardware is already initialised (e.g. by UEFI) then that seems to
cause us problems.
Signed-off-by: Jon Medhurst <tixy@linaro.org>
|
|
User-side code doing double-buffering expects this in the situations
that ends up using mode_set_base.
Also only set scanout as needed, not on every interrupt, as that isn't
required and is unsafe if the framebuffer state is part way through
being updated.
Code adapted from an earlier version of the driver which was written by
Liviu Dudau <Liviu.Dudau@arm.com>
Signed-off-by: Jon Medhurst <tixy@linaro.org>
|
|
This prevents drm_crtc_helper_set_config from doing a full mode_set when
just the the framebuffer start address is changed. E.g. when userside is
implementing double buffering. Without this change, such uses cause
monitors to be in a permanent state of lost signal synchronisation.
Signed-off-by: Jon Medhurst <tixy@linaro.org>
|
|
Signed-off-by: Jon Medhurst <tixy@linaro.org>
|
|
Signed-off-by: Andrew Jackson <Andrew.Jackson@arm.com>
[Updated for Linux 3.18]
Signed-off-by: Jon Medhurst <tixy@linaro.org>
|
|
The average CTS value is based upon the (pixel) clock rate.
Signed-off-by: Andrew Jackson <Andrew.Jackson@arm.com>
Signed-off-by: Jon Medhurst <tixy@linaro.org>
|