The binder_buffer allocator currently only allocates
space for the data and offsets buffers of a Parcel.
This change allows for requesting an additional chunk
of data in the buffer, which can for example be used
to hold additional meta-data about the transaction
(eg a security context).
Change-Id: Iabf59a64ff66a0457a9aa7077aef219c3dc05ba8
Signed-off-by: Martijn Coenen <maco@google.com>
Git-commit: d7c114e9e7
Git-repo: https://git.linaro.org/kernel/linux-linaro-stable
Signed-off-by: Neeraj Upadhyay <neeraju@codeaurora.org>
Moved handling of fixup for binder objects,
handles and file descriptors into separate
functions.
Change-Id: If68c2d93c3a42765cefda40dc807b39f6ab774c2
Signed-off-by: Martijn Coenen <maco@google.com>
Git-commit: 6ea3f1848b
Git-repo: https://git.linaro.org/kernel/linux-linaro-stable
Signed-off-by: Neeraj Upadhyay <neeraju@codeaurora.org>
Add a new module parameter 'devices', that can be
used to specify the names of the binder device
nodes we want to populate in /dev.
Each device node has its own context manager, and
is therefore logically separated from all the other
device nodes.
The config option CONFIG_ANDROID_BINDER_DEVICES can
be used to set the default value of the parameter.
This approach was favored over using IPC namespaces,
mostly because we require a single process to be a
part of multiple binder contexts, which seemed harder
to achieve with namespaces.
Change-Id: Idc765f6186282bdfcf95960d7b4168c5f0992c31
Signed-off-by: Martijn Coenen <maco@google.com>
Git-commit: 5711c305d2
Git-repo: https://git.linaro.org/kernel/linux-linaro-stable
Signed-off-by: Neeraj Upadhyay <neeraju@codeaurora.org>
Move the context manager state into a separate
struct context, and allow for each process to have
its own context associated with it.
Change-Id: I2a1c9adbc01ce1125e4f8661898e7ea4b4904ebe
Signed-off-by: Martijn Coenen <maco@google.com>
Git-commit: e11560a518
Git-repo: https://git.linaro.org/kernel/linux-linaro-stable
Signed-off-by: Neeraj Upadhyay <neeraju@codeaurora.org>
flat_binder_object is used for both handling
binder objects and file descriptors, even though
the two are mostly independent. Since we'll
have more fixup objects in binder in the future,
instead of extending flat_binder_object again,
split out file descriptors to their own object
while retaining backwards compatibility to
existing user-space clients. All binder objects
just share a header.
Change-Id: Ife64444979fba493c1865d2e4f4213ec26d03720
Signed-off-by: Martijn Coenen <maco@google.com>
Git-commit: d8e0aca03a
Git-repo: https://git.linaro.org/kernel/linux-linaro-stable
[neeraju@codeaurora.org: resolve trivial merge conflicts]
Signed-off-by: Neeraj Upadhyay <neeraju@codeaurora.org>
The frequency requested by LMH DCVSh hardware may not match an actual
frequency in the CPU clock plan. LMH DCVSh driver uses OPP framework to
match the hardware frequency request to a nearest valid CPU frequency. OPP
interface expects the frequency input in Hz and DCVSh driver is passing the
frequency value in kHz, which will result in error. So the hardware
mitigation frequency reported by the driver may not reflect the actual
frequency that the CPU is mitigated to.
Provide the hardware frequency input in Hz for OPP interface in LMH DCVSh
driver. Hardware mitigation frequency can be lower than the lowest
possible CPU frequency. In that case freq floor call will fail. So call
dev_pm_opp_find_freq_ceil to match to the lowest CPU frequency.
Change-Id: I6e9f7f5129320c37d41e20ca9735129f25440134
Signed-off-by: Ram Chandrasekar <rkumbako@codeaurora.org>
SDM660 supports multiple GPU power level speed bins. This
change adds all supported GPU power levels speed bins.
Specific speed bin will be used based on efuse value.
Change-Id: Ie542ee2439713ccbba17d38cef5e6ffd95a8b249
Signed-off-by: Deepak Kumar <dkumar@codeaurora.org>
With the new chipset wcn3990 and new firmware HL-1.0, management
is supported via the WMI rather than legacy HTT.
Add support for the management over wmi for the ath10k driver.
CRs-Fixed: 2000484
Change-Id: Iaf387243d63870e063b3b5bf34cd7232dae921fc
Signed-off-by: Rakesh Pillai <pillair@codeaurora.org>
WCN3990 target needs different value for scan flags.
Add proper scan flags for WCN3990 and attach based
on hardware detected.
CRs-Fixed: 1115143
Change-Id: Ie4c02adb5ae65e12d250389d945e048cb6720479
Signed-off-by: Rakesh Pillai <pillair@codeaurora.org>
WCN3990 does not uses BMI for fw download.
Refactor startup sequence to support non BMI
platform.
CRs-Fixed: 1114413
Change-Id: I1e1f5c3808decf319474629ab257ae908895f3a8
Signed-off-by: Govind Singh <govinds@codeaurora.org>
Change enum value of vpx colorspace extradata to align with
the hfi value of vpx colorspace extradata
Change-Id: I3f32842d3ed6d6aa427d5c80a9078efce6c11012
Signed-off-by: Manikanta Sivapala <msivap@codeaurora.org>
HW checksum is not enabled in current release
of WCN3990.
Disable HW checksum for WCN3990.
CRs-Fixed: 2000365
Change-Id: I3b8ee3664150ee8c0c2a8fe9ed1d61c6d32f16b0
Signed-off-by: Govind Singh <govinds@codeaurora.org>
vdev params are being set after vdev is in down state, this
is resulting in firmware crash.
Fix this by skipping vdev access after vdev is in down state.
CRs-Fixed: 2000365
Change-Id: Ib15f038624682fb324fbd5c43fa5cddf462443cd
Signed-off-by: Govind Singh <govinds@codeaurora.org>
Update slope and offset coefficients for charger die
temperature to compensate for temperature compensation
for PM660.
Change-Id: I7884acfdefede6aff2fe4cd3a5745dff0767b4fc
Signed-off-by: Rama Krishna Phani A <rphani@codeaurora.org>
The sched average period can not be 0, disallow setting
it to 0. Otherwise CPUs stuck in sched_avg_update().
Change-Id: Ib9fcc5b35dface09d848ba7a737dc4ac0f05d8ee
Signed-off-by: Pavankumar Kondeti <pkondeti@codeaurora.org>
Add restriction in msm_dolby_dap_param_to_get_control_get
function to avoid reading buffer data with index over
buffer size.
Change-Id: I2bd443d4db1a272d20341fbb5b15891a8acf0bc8
CRs-Fixed: 1096076
Signed-off-by: Yidong Huang <yidongh@codeaurora.org>
WCN3990 is a 37 bit target and needs DMA_MAP of 37 bits.
The HTT RX datapath currently uses 32-bit address.
Refactor the HTT RX datapath to enable DMA MAP of 37 bits for WCN3990.
Fix ath10k_htt_rx_h_ppdu API usage.
CRs-Fixed: 2000491
Change-Id: I3d1505202a899796b0bfa7975844e3700326bfdf
Signed-off-by: Rakesh Pillai <pillair@codeaurora.org>
While enabling ICE setup and on error conditions, the regulator
is disabled. Before disabling the regulator, check if the
regulator is up and able to access the registers of regulator.
Change-Id: I94dd2b3e25444818f7bdf2f791f4fa9efaefce15
Signed-off-by: Brahmaji K <bkomma@codeaurora.org>
rmnet_data netlink handler currently does not check for the
incoming process pid and instead just loops back the pid.
A malicious root user could potentially send a message with
source pid 0 and this could cause rmnet_data to loop the message
back till an out of memory situation occurs.
rmnet_data also does not check for the message length of the
incoming netlink messages and instead casts the netlink message
without checking for the boundary.
Fix these two scenarios by adding the pid and message length checks
respectively.
Bug: 31252965
CRs-Fixed: 1098801
Change-Id: I172c1a7112e67e82959b397af7ddfd963d819bdc
Signed-off-by: Conner Huff <chuff@codeaurora.org>
In function close_ch_worker variable ss_info->cb_data is not set to
NULL after free, this results in crash due to use after free in
notify_for_subsystem function.
This variable is set to NULL to avoid any crash due to use after free.
CRs-Fixed: 2000384
Change-Id: Ia0c7b52e4c8f5d0215fd0ebfbca5e823530f205c
Signed-off-by: Dhoat Harpal <hdhoat@codeaurora.org>
update_task_burst() function's runtime argument type should
be u64 not int. Fix this to avoid potential overflow.
Change-Id: I33757b7b42f142138c1a099bb8be18c2a3bed331
Signed-off-by: Pavankumar Kondeti <pkondeti@codeaurora.org>
In some cases it is useful to manually force the controller to
run at certain speeds (USB 2.0 or USB 3.0 speeds). For example,
EUD (Emebedded USB Debug) can only work when controller is
operating in USB 2.0 speeds. User can force USB 2.0 if EUD is
required.
Change-Id: Id022f372014a9218537bd1b5477d4555aff4578c
Signed-off-by: Vamsi Krishna Samavedam <vskrishn@codeaurora.org>