This reverts commit 5c2fd21b16.
The correspodning commit from android12-5.10 is commit 2f011ad71eea
("FROMLIST: arm64: Add Cortex-A510 CPU part definition").
Bug: 208481398
Change-Id: I5db24cef59523d797e45ffe5139dd73b16f68a21
Signed-off-by: Elliot Berman <quic_eberman@quicinc.com>
This reverts commit 9ada4545d5.
The corresponding commit from android12-5.10 is commit 1a2ec52356de
("FROMLIST: arm64: cpufeature: List early Cortex-A510 parts as having
broken dbm").
Bug: 208481398
Change-Id: If93b35cf677e5abd3c62bc659cc1a0be2b9a2f22
Signed-off-by: Elliot Berman <quic_eberman@quicinc.com>
Enable CONFIG_ARM_SMMU_CONTEXT_FAULT_RETRY for parrot. This is used to
retry the transactin on stall-on-fault model after issuing invalidate.
Change-Id: I286cc5f801b59506180690e96f147b767e41703d
Signed-off-by: Charan Teja Reddy <quic_charante@quicinc.com>
Add CONFIG_ARM_SMMU_CONTEXT_FAULT_RETRY for parrot target. This is used
to retry the transaction after tlb invalidate operation in
stall-on-fault model.
Change-Id: I39dea2ac85c9e67a7115debe4e147d847b6f781c
Signed-off-by: Charan Teja Reddy <quic_charante@quicinc.com>
Currently, we don't trigger dispatcher timer while doing an inline
submission. This breaks the long ib detection. So, trigger dispatcher
timer during an inline submission.
Change-Id: I36397cea3f6ea4393789cd4b54a2258e189f4b13
Signed-off-by: Akhil P Oommen <quic_akhilpo@quicinc.com>
GPIOLIB library doesn't allow to request IRQ line with OUTPUT GPIO
received with gpiod_to_irq() API. Hence get eUSB2 repeater reset PMIC
GPIO related irq using of_irq_get_byname() instead of gpiod_to_irq().
For this functionality repeater device tree node needs to have
interrupt-parent, interrupts and interrupt-names as
"eusb2_rptr_reset_gpio_irq" properties updated.
Also while at it, configure reset_gpio is low by default and assert
it when repeater needs to be reset.
Change-Id: Id1781b933f7f3f2332382b98ad12faff387888eb
Signed-off-by: Pratham Pratap <quic_ppratap@quicinc.com>
When obtaining the UFS error count, cnt_err is always less than
UFS_EVENT_HIST_LENGTH. Such as pa_err_cnt_total, maximum cnt_err of
ufs_qcom_gec is 8, which is unexpectable when it has lots of pa/dl
error. So return cnt from struct ufs_event_hist to fix this error.
Change-Id: I09748f54599a112b8d21121cac83b639c969f508
Signed-off-by: Jun Li <quic_liju@quicinc.com>
Add CONFIG_ARCH_ANORAK to enable support for the Anorak chipset.
Change-Id: If24f7ceb2c76ce4df65d8819fd2ec51d88192304
Signed-off-by: Sahitya Tummala <quic_stummala@quicinc.com>
Added snapshot from msm-5.4 commit a3d4f5d5c3f7
Added snapshot from msm-5.4 commit 8f6d9d8de088
Helioscom driver will be used to communicate with helios device over
spi interface.
Change-Id: If11f295ebeb6456a108697fd1fe3469b7b55581b
Signed-off-by: Ajit Kumar <quic_kajit@quicinc.com>
Signed-off-by: Anurudh Kumar Tiwari <quic_aktiwari@quicinc.com>
During device shutdown smmu driver is doing the force suspend [Thread 1]
and it do smmu power off. It's found that if any non-atomic client
is doing the smmu register space access [Thread 2] during the shutdown
it's leading to unclocked access. To avoid such case adding smmu atomic
power refcount.
Thread 1
Core 1 PC: msm_rtb_get_idx[msm_rtb]+68
...
msm_rtb_get_idx[msm_rtb]+0x68
__log_write_mmio+0x4c
__arm_smmu_tlb_sync[arm_smmu][jt]+0x58
arm_smmu_tlb_sync_context[arm_smmu]+0x50
arm_smmu_tlb_inv_context_s1[arm_smmu]+0x6c
arm_smmu_flush_iotlb_all[arm_smmu]+0x74
_iopgtbl_unmap[msm_kgsl][jt]+0xe0
kgsl_iopgtbl_unmap[msm_kgsl]+0x40
...
Thread 2
Core 5 PC: arch_counter_get_cntvct+18 <ffffffdd574cf228>
...
arm_smmu_power_off[arm_smmu]+0xd4
arm_smmu_runtime_suspend[arm_smmu]+0x1c
pm_generic_runtime_suspend+0x48
pm_runtime_force_suspend+0x74
arm_smmu_device_remove[arm_smmu]+0x120
arm_smmu_device_shutdown[arm_smmu]+0x14
platform_drv_shutdown+0x40
device_shutdown+0x234
...
Change-Id: I1c241a6a43df17e17edc23f6ed879d85c0c3319c
Signed-off-by: Faiyaz Mohammed <quic_faiyazm@quicinc.com>
KGSL waits for GMU to move to active state before triggering preemption.
It is done by polling GMU_CX_GMU_RPMH_POWER_STATE register. KGSL explicitly
keeps GPU alive while handling GPU interrupt, because of which GPU cannot
enter IFPC. Hence, it is guaranteed that GPU will be in active state. Skip
active state transition validation while processing GPU interrupt.
Change-Id: I2f0e06f9bccb1a6b5f3047aa53bf0ff8120ab073
Signed-off-by: Kamal Agrawal <quic_kamaagra@quicinc.com>
Versions of Cortex-A510 before r0p3 are affected by a hardware erratum
where the hardware update of the dirty bit is not correctly ordered.
Add these cpus to the cpu_has_broken_dbm list.
Cc: stable@vger.kernel.org
Signed-off-by: James Morse <james.morse@arm.com>
Bug: 208481398
Link: https://lore.kernel.org/all/20220125154040.549272-3-james.morse@arm.com/
Change-Id: I6ad53c88c034f49f43e61aa2ff3547990583c654
Signed-off-by: Elliot Berman <quic_eberman@quicinc.com>
of_property_count_elems_of_size() API shall return error value
if override_seq is not present as part of repeater device node.
This results into failing repeater probe due to comparing
error value with unsigned int which would result into check
against override_seq_cnt to true. Fix by using int variable to
get return value of of_property_count_elems_of_size() before
validating override_seq parameter size.
Change-Id: I039a99ad252e6660bc265fff3d712ab6ec5f0131
Signed-off-by: Pratham Pratap <quic_ppratap@quicinc.com>
Consider a case where, for some reason, eUSB2 PHY driver
probe gets deferred. Since repeater driver and eUSB PHY
driver are modules they don't have any module loading
dependency. By this time if repeater driver probe is
not called the repeater's device driver structure won't
be populated. Repeater framework will try to release
the resources of the repeater by calling put_repeater
and might run in NULL pointer dereference.
Avoid this by adding NULL pointer check in put_repeater.
Change-Id: I637eb073acd672487d174a966d98c8739df4feb4
Signed-off-by: Pratham Pratap <quic_ppratap@quicinc.com>
If dmabuf deferred_free_thread is preempted then system heap alloc
path is taking longer time due to mutex lock contention. To avoid
preemption due to low priority updating with spin lock.
Change-Id: I63cd224543dc42c0710bc9202bebed9ced2bf341
Signed-off-by: Faiyaz Mohammed <quic_faiyazm@quicinc.com>
This change add proper init sequence for eUSB2 PHY
as per HPG.
Change-Id: Ia1f2d574d9dc0cc072f4ce2a0616d448d1eead52
Signed-off-by: Pratham Pratap <quic_ppratap@quicinc.com>
Add a check to ensure that overflow does not happen in multiplication
operation.
Change-Id: I8b3be6acd92147543ab785c5762a1b2609e5a93d
Signed-off-by: Naman Jain <quic_namajain@quicinc.com>
devm_usb_get_repeater_by_phandle() shall returns ERR_PTR (if usb
repeater device is not found) or pointer to usb repeater
device. Using PTR_ERR against this return value would always
result into true causing eUSB2 PHY driver probe failure. Fix
this issue by using IS_ERR instead of PTR_ERR.
Change-Id: I538160bf0192c7f9e5f75450949dd5161de0e3be
Signed-off-by: Mayank Rana <quic_mrana@quicinc.com>