Re: [PATCH V13 03/14] KVM: x86: Fix Intel PT Host/Guest mode when host tracing also

2024-10-23 Thread Adrian Hunter
On 23/10/24 01:30, Sean Christopherson wrote: > On Tue, Oct 22, 2024, Adrian Hunter wrote: >> On 22/10/24 19:30, Sean Christopherson wrote: >>>>> LOL, yeah, this needs to be burned with fire. It's wildly broken. So >>>>> for stable@, >>&g

Re: [PATCH V13 03/14] KVM: x86: Fix Intel PT Host/Guest mode when host tracing also

2024-10-22 Thread Adrian Hunter
On 22/10/24 19:30, Sean Christopherson wrote: > On Tue, Oct 22, 2024, Adrian Hunter wrote: >> On 14/10/24 21:25, Sean Christopherson wrote: >>>> Fixes: 2ef444f1600b ("KVM: x86: Add Intel PT context switch for each vcpu") >>>> Cc: sta...@vger.kernel.org

Re: [PATCH V13 03/14] KVM: x86: Fix Intel PT Host/Guest mode when host tracing also

2024-10-22 Thread Adrian Hunter
On 14/10/24 21:25, Sean Christopherson wrote: > On Mon, Oct 14, 2024, Adrian Hunter wrote: >> Ensure Intel PT tracing is disabled before VM-Entry in Intel PT Host/Guest >> mode. >> >> Intel PT has 2 modes for tracing virtual machines. The default is System >> mode

[PATCH V13 14/14] perf intel-pt: Add a test for pause / resume

2024-10-14 Thread Adrian Hunter
Add a simple sub-test to the "Miscellaneous Intel PT testing" test to check pause / resume. Signed-off-by: Adrian Hunter Acked-by: Ian Rogers Reviewed-by: Andi Kleen --- tools/perf/tests/shell/test_intel_pt.sh | 28 + 1 file changed, 28 insertions(+) di

[PATCH V13 13/14] perf intel-pt: Add documentation for pause / resume

2024-10-14 Thread Adrian Hunter
Document the use of aux-action config term and provide a simple example. Signed-off-by: Adrian Hunter Acked-by: Ian Rogers Reviewed-by: Andi Kleen --- Changes in V5: Added more examples tools/perf/Documentation/perf-intel-pt.txt | 108 + 1 file changed, 108

[PATCH V13 12/14] perf intel-pt: Improve man page format

2024-10-14 Thread Adrian Hunter
Improve format of config terms and section references. Signed-off-by: Adrian Hunter Acked-by: Ian Rogers Reviewed-by: Andi Kleen --- tools/perf/Documentation/perf-intel-pt.txt | 486 +++-- 1 file changed, 267 insertions(+), 219 deletions(-) diff --git a/tools/perf

[PATCH V13 11/14] perf tools: Add missing_features for aux_start_paused, aux_pause, aux_resume

2024-10-14 Thread Adrian Hunter
Display "feature is not supported" error message if aux_start_paused, aux_pause or aux_resume result in a perf_event_open() error. Signed-off-by: Adrian Hunter Acked-by: Ian Rogers Reviewed-by: Andi Kleen --- Changes in V13: Add error message also in EOPNOTSUPP case (Leo

[PATCH V13 10/14] perf tools: Parse aux-action

2024-10-14 Thread Adrian Hunter
ever, like with aux-output, the events will be automatically grouped if they are not currently in a group, and the AUX area event precedes the other events. Signed-off-by: Adrian Hunter Acked-by: Ian Rogers Reviewed-by: Andi Kleen --- Changes in V8: Fix clang warning:

[PATCH V13 09/14] perf tools: Add aux-action config term

2024-10-14 Thread Adrian Hunter
Add a new common config term "aux-action" to use for configuring AUX area trace pause / resume. The value is a string that will be parsed in a subsequent patch. Signed-off-by: Adrian Hunter Acked-by: Ian Rogers Reviewed-by: Andi Kleen --- Changes in V7: Add aux

[PATCH V13 08/14] perf tools: Add aux_start_paused, aux_pause and aux_resume

2024-10-14 Thread Adrian Hunter
Add struct perf_event_attr members to support pause and resume of AUX area tracing. Signed-off-by: Adrian Hunter Acked-by: Ian Rogers Reviewed-by: Andi Kleen --- tools/include/uapi/linux/perf_event.h | 11 ++- tools/perf/util/perf_event_attr_fprintf.c | 3 +++ 2 files changed, 13

[PATCH V13 07/14] perf/x86/intel: Do not enable large PEBS for events with aux actions or aux sampling

2024-10-14 Thread Adrian Hunter
Events with aux actions or aux sampling expect the PMI to coincide with the event, which does not happen for large PEBS, so do not enable large PEBS in that case. Signed-off-by: Adrian Hunter Reviewed-by: Andi Kleen --- Changes in V11: Remove definition of has_aux_action() because it

[PATCH V13 06/14] perf/x86/intel/pt: Add support for pause / resume

2024-10-14 Thread Adrian Hunter
Prevent tracing to start if aux_paused. Implement support for PERF_EF_PAUSE / PERF_EF_RESUME. When aux_paused, stop tracing. When not aux_paused, only start tracing if it isn't currently meant to be stopped. Signed-off-by: Adrian Hunter Reviewed-by: Andi Kleen --- Changes i

[PATCH V13 05/14] perf/core: Add aux_pause, aux_resume, aux_start_paused

2024-10-14 Thread Adrian Hunter
native_write_msr uname 30805 [000] 24001.058785639: 0x0 Signed-off-by: Adrian Hunter Acked-by: James Clark --- Changes in V13: Do aux_resume at the end of __perf_event_overflow() so as to trace less of perf itself Changes in V12: Rebase on current tip Ch

[PATCH V13 04/14] KVM: selftests: Add guest Intel PT test

2024-10-14 Thread Adrian Hunter
Add a test that starts Intel PT traces on host and guest. The test requires support for Intel PT and having Host/Guest mode enabled i.e. kvm_intel module parameter pt_mode=1. Signed-off-by: Adrian Hunter --- tools/testing/selftests/kvm/Makefile | 1 + .../selftests/kvm/include/x86_64

[PATCH V13 03/14] KVM: x86: Fix Intel PT Host/Guest mode when host tracing also

2024-10-14 Thread Adrian Hunter
uest mode. That also fixes the issue whereby the Intel PT NMI handler would set IA32_RTIT_CTL.TraceEn back to 1 after KVM has just set it to 0. Fixes: 2ef444f1600b ("KVM: x86: Add Intel PT context switch for each vcpu") Cc: sta...@vger.kernel.org Signed-off-by: Adrian Hunter --- arch/x8

[PATCH V13 02/14] KVM: x86: Fix Intel PT IA32_RTIT_CTL MSR validation

2024-10-14 Thread Adrian Hunter
;) Cc: sta...@vger.kernel.org Signed-off-by: Adrian Hunter --- arch/x86/kvm/vmx/vmx.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/arch/x86/kvm/vmx/vmx.c b/arch/x86/kvm/vmx/vmx.c index 1a4438358c5e..eaf4965ac6df 100644 --- a/arch/x86/kvm/vmx/vmx.c +++ b/arch/x86/kvm/vmx/vmx.c

[PATCH V13 01/14] perf/x86/intel/pt: Fix buffer full but size is 0 case

2024-10-14 Thread Adrian Hunter
l PT PMU driver") Cc: sta...@vger.kernel.org Signed-off-by: Adrian Hunter --- arch/x86/events/intel/pt.c | 11 --- arch/x86/events/intel/pt.h | 2 ++ 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/arch/x86/events/intel/pt.c b/arch/x86/events/intel/pt.c index fd4670a6694e..a087

[PATCH V13 00/14] perf/core: Add ability for an event to "pause" or "resume" AUX area tracing

2024-10-14 Thread Adrian Hunter
or pause / resume 'mode' -> 'flags' so it at least compiles Changes in RFC V2: Use ->stop() / ->start() instead of ->pause_resume() Move aux_start_paused bit into aux_output_cfg Tighten up when Intel PT pause / resume is allowed Add

[PATCH V12 02/14] KVM: x86: Fix Intel PT IA32_RTIT_CTL MSR validation

2024-10-10 Thread Adrian Hunter
;) Cc: sta...@vger.kernel.org Signed-off-by: Adrian Hunter --- arch/x86/kvm/vmx/vmx.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/arch/x86/kvm/vmx/vmx.c b/arch/x86/kvm/vmx/vmx.c index 1a4438358c5e..eaf4965ac6df 100644 --- a/arch/x86/kvm/vmx/vmx.c +++ b/arch/x86/kvm/vmx/vmx.c

[PATCH V12 08/14] perf tools: Add aux_start_paused, aux_pause and aux_resume

2024-10-10 Thread Adrian Hunter
Add struct perf_event_attr members to support pause and resume of AUX area tracing. Signed-off-by: Adrian Hunter Acked-by: Ian Rogers Reviewed-by: Andi Kleen --- tools/include/uapi/linux/perf_event.h | 11 ++- tools/perf/util/perf_event_attr_fprintf.c | 3 +++ 2 files changed, 13

[PATCH V12 14/14] perf intel-pt: Add a test for pause / resume

2024-10-10 Thread Adrian Hunter
Add a simple sub-test to the "Miscellaneous Intel PT testing" test to check pause / resume. Signed-off-by: Adrian Hunter Acked-by: Ian Rogers Reviewed-by: Andi Kleen --- tools/perf/tests/shell/test_intel_pt.sh | 28 + 1 file changed, 28 insertions(+) di

[PATCH V12 13/14] perf intel-pt: Add documentation for pause / resume

2024-10-10 Thread Adrian Hunter
Document the use of aux-action config term and provide a simple example. Signed-off-by: Adrian Hunter Acked-by: Ian Rogers Reviewed-by: Andi Kleen --- Changes in V5: Added more examples tools/perf/Documentation/perf-intel-pt.txt | 108 + 1 file changed, 108

[PATCH V12 12/14] perf intel-pt: Improve man page format

2024-10-10 Thread Adrian Hunter
Improve format of config terms and section references. Signed-off-by: Adrian Hunter Acked-by: Ian Rogers Reviewed-by: Andi Kleen --- tools/perf/Documentation/perf-intel-pt.txt | 486 +++-- 1 file changed, 267 insertions(+), 219 deletions(-) diff --git a/tools/perf

[PATCH V12 11/14] perf tools: Add missing_features for aux_start_paused, aux_pause, aux_resume

2024-10-10 Thread Adrian Hunter
Display "feature is not supported" error message if aux_start_paused, aux_pause or aux_resume result in a perf_event_open() error. Signed-off-by: Adrian Hunter Acked-by: Ian Rogers Reviewed-by: Andi Kleen --- tools/perf/util/evsel.c | 10 +- tools/perf/util/evsel.h | 1

[PATCH V12 10/14] perf tools: Parse aux-action

2024-10-10 Thread Adrian Hunter
ever, like with aux-output, the events will be automatically grouped if they are not currently in a group, and the AUX area event precedes the other events. Signed-off-by: Adrian Hunter Acked-by: Ian Rogers Reviewed-by: Andi Kleen --- Changes in V8: Fix clang warning:

[PATCH V12 09/14] perf tools: Add aux-action config term

2024-10-10 Thread Adrian Hunter
Add a new common config term "aux-action" to use for configuring AUX area trace pause / resume. The value is a string that will be parsed in a subsequent patch. Signed-off-by: Adrian Hunter Acked-by: Ian Rogers Reviewed-by: Andi Kleen --- Changes in V7: Add aux

[PATCH V12 07/14] perf/x86/intel: Do not enable large PEBS for events with aux actions or aux sampling

2024-10-10 Thread Adrian Hunter
Events with aux actions or aux sampling expect the PMI to coincide with the event, which does not happen for large PEBS, so do not enable large PEBS in that case. Signed-off-by: Adrian Hunter Reviewed-by: Andi Kleen --- Changes in V11: Remove definition of has_aux_action() because it

[PATCH V12 06/14] perf/x86/intel/pt: Add support for pause / resume

2024-10-10 Thread Adrian Hunter
Prevent tracing to start if aux_paused. Implement support for PERF_EF_PAUSE / PERF_EF_RESUME. When aux_paused, stop tracing. When not aux_paused, only start tracing if it isn't currently meant to be stopped. Signed-off-by: Adrian Hunter Reviewed-by: Andi Kleen --- Changes i

[PATCH V12 05/14] perf/core: Add aux_pause, aux_resume, aux_start_paused

2024-10-10 Thread Adrian Hunter
native_write_msr uname 30805 [000] 24001.058785639: 0x0 Signed-off-by: Adrian Hunter Acked-by: James Clark --- Changes in V12: Rebase on current tip Changes in V11: Make assignment to event->hw.aux_paused conditional on (pmu->capabilities & PERF_PMU_CAP_AUX

[PATCH V12 04/14] KVM: selftests: Add guest Intel PT test

2024-10-10 Thread Adrian Hunter
Add a test that starts Intel PT traces on host and guest. The test requires support for Intel PT and having Host/Guest mode enabled i.e. kvm_intel module parameter pt_mode=1. Signed-off-by: Adrian Hunter --- tools/testing/selftests/kvm/Makefile | 1 + .../selftests/kvm/include/x86_64

[PATCH V12 03/14] KVM: x86: Fix Intel PT Host/Guest mode when host tracing also

2024-10-10 Thread Adrian Hunter
uest mode. That also fixes the issue whereby the Intel PT NMI handler would set IA32_RTIT_CTL.TraceEn back to 1 after KVM has just set it to 0. Fixes: 2ef444f1600b ("KVM: x86: Add Intel PT context switch for each vcpu") Cc: sta...@vger.kernel.org Signed-off-by: Adrian Hunter --- arch/x8

[PATCH V12 01/14] perf/x86/intel/pt: Fix buffer full but size is 0 case

2024-10-10 Thread Adrian Hunter
l PT PMU driver") Cc: sta...@vger.kernel.org Signed-off-by: Adrian Hunter --- arch/x86/events/intel/pt.c | 11 --- arch/x86/events/intel/pt.h | 2 ++ 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/arch/x86/events/intel/pt.c b/arch/x86/events/intel/pt.c index fd4670a6694e..a087

[PATCH V12 00/14] perf/core: Add ability for an event to "pause" or "resume" AUX area tracing

2024-10-10 Thread Adrian Hunter
7;mode' -> 'flags' so it at least compiles Changes in RFC V2: Use ->stop() / ->start() instead of ->pause_resume() Move aux_start_paused bit into aux_output_cfg Tighten up when Intel PT pause / resume is allowed Add an example of how

Re: [PATCH 0/3] KVM: x86: Fix Intel PT Host/Guest mode when host tracing also

2024-10-04 Thread Adrian Hunter
On 26/09/24 17:05, Adrian Hunter wrote: > On 6/09/24 16:00, Adrian Hunter wrote: >> Hi >> >> There is a long-standing problem whereby running Intel PT on host and guest >> in Host/Guest mode, causes VM-Entry failure. >> >> The motivation for this patch set

Re: [PATCH 0/3] KVM: x86: Fix Intel PT Host/Guest mode when host tracing also

2024-09-26 Thread Adrian Hunter
On 6/09/24 16:00, Adrian Hunter wrote: > Hi > > There is a long-standing problem whereby running Intel PT on host and guest > in Host/Guest mode, causes VM-Entry failure. > > The motivation for this patch set is to provide a fix for stable kernels > prior to the ad

[PATCH 3/3] KVM: selftests: Add guest Intel PT test

2024-09-06 Thread Adrian Hunter
Add a test that starts Intel PT traces on host and guest. The test requires support for Intel PT and having Host/Guest mode enabled i.e. kvm_intel module parameter pt_mode=1. Signed-off-by: Adrian Hunter --- tools/testing/selftests/kvm/Makefile | 1 + .../selftests/kvm/include/x86_64

[PATCH 2/3] KVM: x86: Fix Intel PT Host/Guest mode when host tracing also

2024-09-06 Thread Adrian Hunter
uest mode. That also fixes the issue whereby the Intel PT NMI handler would set IA32_RTIT_CTL.TraceEn back to 1 after KVM has just set it to 0. Fixes: 2ef444f1600b ("KVM: x86: Add Intel PT context switch for each vcpu") Cc: sta...@vger.kernel.org Signed-off-by: Adrian Hunter --- arch/x8

[PATCH 1/3] KVM: x86: Fix Intel PT IA32_RTIT_CTL MSR validation

2024-09-06 Thread Adrian Hunter
;) Cc: sta...@vger.kernel.org Signed-off-by: Adrian Hunter --- arch/x86/kvm/vmx/vmx.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/arch/x86/kvm/vmx/vmx.c b/arch/x86/kvm/vmx/vmx.c index f18c2d8c7476..3f1e3be552c0 100644 --- a/arch/x86/kvm/vmx/vmx.c +++ b/arch/x86/kvm/vmx/vmx.c

[PATCH 0/3] KVM: x86: Fix Intel PT Host/Guest mode when host tracing also

2024-09-06 Thread Adrian Hunter
ix does not conflict with "Mediated Passthrough vPMU", it is just that "Mediated Passthrough vPMU" will make the code to stop and restart Intel PT unnecessary. Adrian Hunter (3): KVM: x86: Fix Intel PT IA32_RTIT_CTL MSR validation KVM: x86: Fix Intel PT Host/Gue

Re: [PATCH v4 0/9] uprobes: misc cleanups/simplifications

2024-08-02 Thread Adrian Hunter
On 2/08/24 14:02, Adrian Hunter wrote: > On 2/08/24 12:25, Peter Zijlstra wrote: >> On Thu, Aug 01, 2024 at 02:13:41PM -0700, Andrii Nakryiko wrote: >> >>> Ok, this bisected to: >>> >>> 675ad74989c2 ("perf/core: Add aux_pause, aux_resume, aux_star

Re: [PATCH v4 0/9] uprobes: misc cleanups/simplifications

2024-08-02 Thread Adrian Hunter
On 2/08/24 12:25, Peter Zijlstra wrote: > On Thu, Aug 01, 2024 at 02:13:41PM -0700, Andrii Nakryiko wrote: > >> Ok, this bisected to: >> >> 675ad74989c2 ("perf/core: Add aux_pause, aux_resume, aux_start_paused") > > Adrian, there are at least two obvious bugs there: > > - aux_action was key's o

Re: [PATCH] perf auxtrace: Fix potential null pointer dereference

2021-04-20 Thread Adrian Hunter
gt; callback pointer "itr->parse_snapshot_options" is dereferenced without > performing NULL check. > > Add a NULL check for the pointer "itr->parse_snapshot_options" before > invoke the callback. > > Fixes: d20031bb63dd ("perf tools: Add AUX area tracing Snapshot Mode&

Re: [PATCH v4 1/2] mmc: block: Issue flush only if allowed

2021-04-20 Thread Adrian Hunter
way, verify that The cache function is > turned ON before doing so. > > fixes: 1e8e55b67030 (mmc: block: Add CQE support) > > Reported-by: Brendan Peter > Tested-by: Brendan Peter > Signed-off-by: Avri Altman Acked-by: Adrian Hunter > --- > drivers/mmc/core/bloc

Re: [PATCH v3 2/2] mmc: block: Update ext_csd.cache_ctrl if it was written

2021-04-20 Thread Adrian Hunter
ctrl on ext-csd write. > > Signed-off-by: Avri Altman Acked-by: Adrian Hunter > --- > drivers/mmc/core/block.c | 12 > 1 file changed, 12 insertions(+) > > diff --git a/drivers/mmc/core/block.c b/drivers/mmc/core/block.c > index 5b6501fc9fb7..8b07ed5e08de 10

Re: [PATCH v3 1/2] mmc: block: Issue flush only if allowed

2021-04-20 Thread Adrian Hunter
On 20/04/21 8:53 am, Avri Altman wrote: > The cache may be flushed to the nonvolatile storage by writing to > FLUSH_CACHE byte (EXT_CSD byte [32]). When in command queueing mode, the > cache may be flushed by issuing a CMDQ_TASK_ DEV_MGMT (CMD48) with a > FLUSH_CACHE op-code. Either way, verify th

Re: [PATCH v20 1/2] scsi: ufs: Enable power management for wlun

2021-04-20 Thread Adrian Hunter
On 20/04/21 7:15 am, Adrian Hunter wrote: > On 20/04/21 12:53 am, Asutosh Das (asd) wrote: >> On 4/19/2021 11:37 AM, Adrian Hunter wrote: >>> On 16/04/21 10:49 pm, Asutosh Das wrote: >>>> >>>> Co-developed-by: Can Guo >>>> S

Re: [PATCH v20 1/2] scsi: ufs: Enable power management for wlun

2021-04-19 Thread Adrian Hunter
On 20/04/21 12:53 am, Asutosh Das (asd) wrote: > On 4/19/2021 11:37 AM, Adrian Hunter wrote: >> On 16/04/21 10:49 pm, Asutosh Das wrote: >>> >>> Co-developed-by: Can Guo >>> Signed-off-by: Can Guo >>> Signed-off-by: Asutosh Das >>> --- >

Re: [PATCH v20 1/2] scsi: ufs: Enable power management for wlun

2021-04-19 Thread Adrian Hunter
On 16/04/21 10:49 pm, Asutosh Das wrote: > During runtime-suspend of ufs host, the scsi devices are > already suspended and so are the queues associated with them. > But the ufs host sends SSU (START_STOP_UNIT) to wlun > during its runtime-suspend. > During the process blk_queue_enter checks if the

Re: [PATCH] scsi: ufs: Check for bkops in runtime suspend

2021-04-18 Thread Adrian Hunter
On 18/04/21 10:21 am, Avri Altman wrote: > The UFS driver allowed BKOPS and WB Flush operations to be completed on > Runtime suspend. Adding the DeepSleep support, this is no longer true: > the driver will ignore BKOPS and WB Flush states, and force a link state > transition to UIC_LINK_OFF_STATE.

Re: [PATCH v19 1/2] scsi: ufs: Enable power management for wlun

2021-04-16 Thread Adrian Hunter
On 16/04/21 12:22 pm, Adrian Hunter wrote: > On 16/04/21 2:36 am, Asutosh Das wrote: >> During runtime-suspend of ufs host, the scsi devices are >> already suspended and so are the queues associated with them. >> But the ufs host sends SSU (START_STOP_UNIT) to wlun >>

Re: [PATCH v19 1/2] scsi: ufs: Enable power management for wlun

2021-04-16 Thread Adrian Hunter
On 16/04/21 2:36 am, Asutosh Das wrote: > During runtime-suspend of ufs host, the scsi devices are > already suspended and so are the queues associated with them. > But the ufs host sends SSU (START_STOP_UNIT) to wlun > during its runtime-suspend. > During the process blk_queue_enter checks if the

Re: [PATCH v18 1/2] scsi: ufs: Enable power management for wlun

2021-04-15 Thread Adrian Hunter
On 14/04/21 9:58 pm, Asutosh Das wrote: > During runtime-suspend of ufs host, the scsi devices are > already suspended and so are the queues associated with them. > But the ufs host sends SSU (START_STOP_UNIT) to wlun > during its runtime-suspend. > During the process blk_queue_enter checks if the

Re: [PATCH v18 2/2] ufs: sysfs: Resume the proper scsi device

2021-04-15 Thread Adrian Hunter
On 14/04/21 9:58 pm, Asutosh Das wrote: > Resumes the actual scsi device the unit descriptor of which > is being accessed instead of the hba alone. > > Reviewed-by: Can Guo > Signed-off-by: Asutosh Das Reviewed-by: Adrian Hunter > --- > drivers/scsi

Re: [PATCH 2/2] perf intel-pt: Use aux_watermark

2021-04-13 Thread Adrian Hunter
On 8/04/21 6:31 pm, Alexander Shishkin wrote: > Turns out, the default setting of attr.aux_watermark to half of the total > buffer size is not very useful, especially with smaller buffers. The > problem is that, after half of the buffer is filled up, the kernel updates > ->aux_head and sets up the

Re: [PATCH v17 1/2] scsi: ufs: Enable power management for wlun

2021-04-11 Thread Adrian Hunter
On 8/04/21 5:49 pm, Asutosh Das wrote: > During runtime-suspend of ufs host, the scsi devices are > already suspended and so are the queues associated with them. > But the ufs host sends SSU (START_STOP_UNIT) to wlun > during its runtime-suspend. > During the process blk_queue_enter checks if the q

Re: [PATCH v17 2/2] ufs: sysfs: Resume the proper scsi device

2021-04-10 Thread Adrian Hunter
On 8/04/21 5:49 pm, Asutosh Das wrote: > Resumes the actual scsi device the unit descriptor of which > is being accessed instead of the hba alone. > > Reviewed-by: Can Guo > Signed-off-by: Asutosh Das > --- > drivers/scsi/ufs/ufs-sysfs.c | 30 +- > 1 file changed, 17

Re: [PATCH] perf session: Dump PERF_RECORD_TIME_CONV event

2021-04-10 Thread Adrian Hunter
On 10/04/21 6:19 am, Leo Yan wrote: > Now perf tool uses the common stub function process_event_op2_stub() for > dumping TIME_CONV event, thus it doesn't output the clock parameters > contained in the event. > > This patch adds the callback function for dumping the hardware clock > parameters in T

Re: [PATCH v17 1/2] scsi: ufs: Enable power management for wlun

2021-04-09 Thread Adrian Hunter
On 9/04/21 8:15 pm, Asutosh Das (asd) wrote: > On 4/9/2021 3:07 AM, Adrian Hunter wrote: >> On 9/04/21 5:27 am, Daejun Park wrote: >>> Hi Asutosh Das, >>> >>>> During runtime-suspend of ufs host, the scsi devices are >>>> already suspended and s

Re: [PATCH v17 1/2] scsi: ufs: Enable power management for wlun

2021-04-09 Thread Adrian Hunter
On 9/04/21 5:27 am, Daejun Park wrote: > Hi Asutosh Das, > >> During runtime-suspend of ufs host, the scsi devices are >> already suspended and so are the queues associated with them. >> But the ufs host sends SSU (START_STOP_UNIT) to wlun >> during its runtime-suspend. >> During the process blk_q

Re: [PATCH v16 1/2] scsi: ufs: Enable power management for wlun

2021-04-08 Thread Adrian Hunter
On 7/04/21 9:08 pm, Asutosh Das wrote: > During runtime-suspend of ufs host, the scsi devices are > already suspended and so are the queues associated with them. > But the ufs host sends SSU (START_STOP_UNIT) to wlun > during its runtime-suspend. > During the process blk_queue_enter checks if the q

Re: [PATCH v2 0/7] perf arm-spe: Enable timestamp

2021-04-07 Thread Adrian Hunter
On 7/04/21 4:15 pm, Leo Yan wrote: > Hi Al, > > On Tue, Apr 06, 2021 at 09:38:32AM +, Al Grant wrote: > > [...] > >>> This patch set is to enable timestamp for Arm SPE trace. It reads out TSC >>> parameters from mmap page and stores into auxtrace info structure; >> >> Why not synthesize a P

Re: [PATCH v15 1/2] scsi: ufs: Enable power management for wlun

2021-04-07 Thread Adrian Hunter
On 6/04/21 8:52 pm, Asutosh Das wrote: > During runtime-suspend of ufs host, the scsi devices are > already suspended and so are the queues associated with them. > But the ufs host sends SSU (START_STOP_UNIT) to wlun > during its runtime-suspend. > During the process blk_queue_enter checks if the q

[PATCH] perf inject: Fix repipe usage

2021-04-01 Thread Adrian Hunter
' is true. Fix by setting 'repipe' to true only if the output is a pipe. Fixes: e558a5bd8b74 ("perf inject: Work with files") Signed-off-by: Adrian Hunter --- tools/perf/builtin-inject.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/perf/builti

Re: [PATCH v14 1/2] scsi: ufs: Enable power management for wlun

2021-04-01 Thread Adrian Hunter
On 1/04/21 4:40 am, Asutosh Das (asd) wrote: > On 3/31/2021 11:19 AM, Adrian Hunter wrote: >> On 31/03/21 1:31 am, Asutosh Das wrote: >>> During runtime-suspend of ufs host, the scsi devices are >>> already suspended and so are the queues associated with them. >

Re: [PATCH v14 1/2] scsi: ufs: Enable power management for wlun

2021-03-31 Thread Adrian Hunter
On 31/03/21 1:31 am, Asutosh Das wrote: > During runtime-suspend of ufs host, the scsi devices are > already suspended and so are the queues associated with them. > But the ufs host sends SSU (START_STOP_UNIT) to wlun > during its runtime-suspend. > During the process blk_queue_enter checks if the

Re: [PATCH v13 1/2] scsi: ufs: Enable power management for wlun

2021-03-30 Thread Adrian Hunter
On 25/03/21 3:39 am, Asutosh Das wrote: > During runtime-suspend of ufs host, the scsi devices are > already suspended and so are the queues associated with them. > But the ufs host sends SSU (START_STOP_UNIT) to wlun > during its runtime-suspend. > During the process blk_queue_enter checks if the

Re: [PATCH v12 1/2] scsi: ufs: Enable power management for wlun

2021-03-25 Thread Adrian Hunter
On 25/03/21 4:14 am, Asutosh Das (asd) wrote: > On 3/23/2021 12:19 PM, Adrian Hunter wrote: >> On 23/03/21 5:13 pm, Asutosh Das (asd) wrote: >>> On 3/22/2021 11:12 PM, Adrian Hunter wrote: >>>> On 22/03/21 9:53 pm, Asutosh Das (asd) wrote: >>>>&g

Re: [PATCH v12 1/2] scsi: ufs: Enable power management for wlun

2021-03-23 Thread Adrian Hunter
On 23/03/21 5:13 pm, Asutosh Das (asd) wrote: > On 3/22/2021 11:12 PM, Adrian Hunter wrote: >> On 22/03/21 9:53 pm, Asutosh Das (asd) wrote: >>> On 3/19/2021 10:47 AM, Adrian Hunter wrote: >>>> On 19/03/21 2:35 am, Asutosh Das wrote: >>>>> During runt

Re: [PATCH v12 1/2] scsi: ufs: Enable power management for wlun

2021-03-22 Thread Adrian Hunter
On 22/03/21 9:53 pm, Asutosh Das (asd) wrote: > On 3/19/2021 10:47 AM, Adrian Hunter wrote: >> On 19/03/21 2:35 am, Asutosh Das wrote: >>> During runtime-suspend of ufs host, the scsi devices are >>> already suspended and so are the queues associated with them. >&g

Re: [PATCH 2/2] mmc: block: Update ext_csd.cache_ctrl if it was written

2021-03-22 Thread Adrian Hunter
On 22/03/21 3:36 pm, Avri Altman wrote: > The cache function can be turned ON and OFF by writing to the CACHE_CTRL > byte (EXT_CSD byte [33]). However, card->ext_csd.cache_ctrl is only > set on init if cache size > 0. > > Fix that by explicitly setting ext_csd.cache_ctrl on ext-csd write. > > S

Re: [PATCH 1/2] mmc: block: Issue flush only if allowed

2021-03-22 Thread Adrian Hunter
On 22/03/21 3:36 pm, Avri Altman wrote: > The cache may be flushed to the nonvolatile storage by writing to > FLUSH_CACHE byte (EXT_CSD byte [32]). When in command queueing mode, the > cache may be flushed by issuing a CMDQ_TASK_ DEV_MGMT (CMD48) with a > FLUSH_CACHE op-code. Either way, verify th

Re: [PATCH v12 1/2] scsi: ufs: Enable power management for wlun

2021-03-19 Thread Adrian Hunter
On 19/03/21 2:35 am, Asutosh Das wrote: > During runtime-suspend of ufs host, the scsi devices are > already suspended and so are the queues associated with them. > But the ufs host sends SSU to wlun during its runtime-suspend. > During the process blk_queue_enter checks if the queue is not in > su

Re: [PATCH v10 1/2] scsi: ufs: Enable power management for wlun

2021-03-18 Thread Adrian Hunter
On 18/03/21 7:58 pm, Asutosh Das (asd) wrote: > On 3/18/2021 10:54 AM, Rafael J. Wysocki wrote: >> On Thu, Mar 18, 2021 at 6:33 PM Asutosh Das (asd) >> wrote: >>> >>> On 3/18/2021 7:00 AM, Rafael J. Wysocki wrote: >>>> On Wed, Mar 17, 2021 at 7:37 AM

Re: [PATCH v10 1/2] scsi: ufs: Enable power management for wlun

2021-03-16 Thread Adrian Hunter
On 16/03/21 10:35 pm, Asutosh Das (asd) wrote: > On 3/16/2021 12:48 AM, Adrian Hunter wrote: >> On 16/03/21 12:22 am, Asutosh Das (asd) wrote: >>> On 3/14/2021 1:11 AM, Adrian Hunter wrote: >>>> On 10/03/21 5:04 am, Asutosh Das (asd) wrote: >>>>>

Re: [PATCH v10 1/2] scsi: ufs: Enable power management for wlun

2021-03-16 Thread Adrian Hunter
On 16/03/21 12:22 am, Asutosh Das (asd) wrote: > On 3/14/2021 1:11 AM, Adrian Hunter wrote: >> On 10/03/21 5:04 am, Asutosh Das (asd) wrote: >>> On 3/9/2021 7:56 AM, Asutosh Das (asd) wrote: >>>> On 3/8/2021 9:17 AM, Rafael J. Wysocki wrote: >>>>> On

Re: [PATCH v1 1/1] mmc: sdhci-acpi: Add support for NVIDIA BlueField-3 SoC

2021-03-15 Thread Adrian Hunter
that is generally preferred I think. > >> -Original Message----- >> From: Adrian Hunter >> Sent: Monday, March 15, 2021 4:34 AM >> To: Liming Sun ; Ulf Hansson ; >> Khalil Blaiech >> Cc: linux-...@vger.kernel.org; linux-kernel@vger.kernel.org >> Subje

Re: [PATCH v11 1/2] scsi: ufs: Enable power management for wlun

2021-03-15 Thread Adrian Hunter
On 12/03/21 12:19 am, Asutosh Das wrote: > During runtime-suspend of ufs host, the scsi devices are > already suspended and so are the queues associated with them. > But the ufs host sends SSU to wlun during its runtime-suspend. > During the process blk_queue_enter checks if the queue is not in > s

Re: [PATCH v1 1/1] mmc: sdhci-acpi: Add support for NVIDIA BlueField-3 SoC

2021-03-15 Thread Adrian Hunter
On 12/03/21 3:48 pm, Liming Sun wrote: > This commit adds ACPI support for the BlueField-3 SoC which uses > the DWC_mshc eMMC controller. The boundary check logic in static > function dwcmshc_adma_write_desc() comes from sdhci-of-dwcmshc.c. Did you consider adding ACPI support to sdhci-of-dwcmshc.

Re: [PATCH v10 1/2] scsi: ufs: Enable power management for wlun

2021-03-14 Thread Adrian Hunter
On 10/03/21 5:04 am, Asutosh Das (asd) wrote: > On 3/9/2021 7:56 AM, Asutosh Das (asd) wrote: >> On 3/8/2021 9:17 AM, Rafael J. Wysocki wrote: >>> On Mon, Mar 8, 2021 at 5:21 PM Rafael J. Wysocki wrote: On Sat, Mar 6, 2021 at 5:17 PM Alan Stern wrote: > > On Fri, Mar 05, 2

[PATCH] scsi: ufs-pci: Add support for Intel LKF

2021-03-12 Thread Adrian Hunter
Add PCI ID and callbacks to support Intel LKF. This includes the ability to use an ACPI device-specific method (DSM) to perform a UFS device reset. Signed-off-by: Adrian Hunter --- drivers/scsi/ufs/ufshcd-pci.c | 169 ++ 1 file changed, 169 insertions(+) diff

Re: [PATCH] mmc: sdhci-pci: Avoid comma separated statements

2021-03-11 Thread Adrian Hunter
On 11/03/21 12:14 pm, Jisheng Zhang wrote: > Use semicolons. > > Signed-off-by: Jisheng Zhang Acked-by: Adrian Hunter > --- > drivers/mmc/host/sdhci-pci-core.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/mmc/host/sdhci-pci-core

Re: [PATCH] mmc: sdhci: Use "mmc" directly rather than "host->mmc"

2021-03-11 Thread Adrian Hunter
11000463add w3, w3, #0x1 > 908: 94000000bl 0 > ... > > We saved one ldr instruction: "ldr x0, [x0, #1160]" > > Signed-off-by: Jisheng Zhang Acked-by: Adrian Hunter > --- > drivers/mmc/host/sdhci.c | 33 ++

[PATCH] perf auxtrace: Fix auxtrace queue conflict

2021-03-08 Thread Adrian Hunter
sample mode to trace multiple threads. Consequently, fix that case by removing the check. Reported-by: Andi Kleen Fixes: e502789302a6 ("perf auxtrace: Add helpers for queuing AUX area tracing data") Signed-off-by: Adrian Hunter --- tools/perf/util/auxtrace.c | 4 1 file

Re: [PATCH v10 1/2] scsi: ufs: Enable power management for wlun

2021-03-04 Thread Adrian Hunter
On 3/03/21 12:52 am, Asutosh Das wrote: > During runtime-suspend of ufs host, the scsi devices are > already suspended and so are the queues associated with them. > But the ufs host sends SSU to wlun during its runtime-suspend. > During the process blk_queue_enter checks if the queue is not in > su

Re: [PATCH v10 2/2] ufs: sysfs: Resume the proper scsi device

2021-03-03 Thread Adrian Hunter
On 3/03/21 12:52 am, Asutosh Das wrote: > Resumes the actual scsi device the unit descriptor of which > is being accessed instead of the hba alone. Since "scsi: ufs: ufs-debugfs: Add user-defined exception_event_mask" is now in linux-next, a similar change is needed for ufs-debugfs.c. Probably bes

Re: [PATCH v2 1/1] mmc: cqhci: fix random crash when remove mmc module

2021-03-03 Thread Adrian Hunter
(2) pass check here > cq_host->enable = false; > > task_desc= > get_desc(cq_host,tag); > ^^^^ crash here > (3) acces

Re: [PATCH V1] mmc: sdhci: Check for reset prior to DMA address unmap

2021-03-03 Thread Adrian Hunter
completed. So we don't run into this > scenario. > > Swap the reset, un-map steps sequence in sdhci_request_done(). > > Suggested-by: Veerabhadrarao Badiganti > Signed-off-by: Pradeep P V K Seems like a good change to make. A couple of cosmetic tweaks below, but: Acked-by:

Re: [PATCH 1/1] mmc: cqhci: fix random crash when remove mmc module

2021-03-02 Thread Adrian Hunter
On 2/03/21 5:12 pm, Zhi Li wrote: > > > On Tue, Mar 2, 2021 at 1:03 AM Adrian Hunter <mailto:adrian.hun...@intel.com>> wrote: > > On 1/03/21 7:21 pm, Frank Li wrote: > > [ 6684.493350] Unable to handle kernel paging request at virtual > address 8

Re: [PATCH v9 1/2] scsi: ufs: Enable power management for wlun

2021-03-02 Thread Adrian Hunter
On 2/03/21 5:21 am, Asutosh Das wrote: > During runtime-suspend of ufs host, the scsi devices are > already suspended and so are the queues associated with them. > But the ufs host sends SSU to wlun during its runtime-suspend. > During the process blk_queue_enter checks if the queue is not in > sus

Re: [PATCH] scsi: ufs: Fix incorrect ufshcd_state after ufshcd_reset_and_restore()

2021-03-02 Thread Adrian Hunter
start of each >> loop in ufshcd_reset_and_restore(). If there is an error, >> ufshcd_reset_and_restore() will change the state to UFSHCD_STATE_ERROR, >> otherwise ufshcd_probe_hba() will have set the state appropriately. >> >> Fixes: 4db7a2360597 ("scsi: ufs: Fi

Re: [PATCH 1/1] mmc: cqhci: fix random crash when remove mmc module

2021-03-02 Thread Adrian Hunter
On 1/03/21 7:21 pm, Frank Li wrote: > [ 6684.493350] Unable to handle kernel paging request at virtual address > 800011c5b0f0 > [ 6684.498531] mmc0: card 0001 removed > [ 6684.501556] Mem abort info: > [ 6684.509681] ESR = 0x9647 > [ 6684.512786] EC = 0x25: DABT (current EL), IL = 32 b

[PATCH] scsi: ufs: Fix incorrect ufshcd_state after ufshcd_reset_and_restore()

2021-03-01 Thread Adrian Hunter
UFSHCD_STATE_ERROR, otherwise ufshcd_probe_hba() will have set the state appropriately. Fixes: 4db7a2360597 ("scsi: ufs: Fix concurrency of error handler and other error recovery paths") Signed-off-by: Adrian Hunter --- drivers/scsi/ufs/ufshcd.c | 2 ++ 1 file changed, 2 insertions(+) di

Re: [PATCH v8 1/2] scsi: ufs: Enable power management for wlun

2021-03-01 Thread Adrian Hunter
On 1/03/21 8:10 pm, Asutosh Das wrote: > On Mon, Mar 01 2021 at 05:23 -0800, Adrian Hunter wrote: >> On 26/02/21 1:37 am, Asutosh Das wrote: >>> @@ -8901,43 +9125,14 @@ static int ufshcd_resume(struct ufs_hba *hba, enum >>> ufs_pm_op pm_op) >>&

Re: [PATCH v8 1/2] scsi: ufs: Enable power management for wlun

2021-03-01 Thread Adrian Hunter
Hi A couple of minor things, but also a potential issue with when link state transitions are done. Please see comments below. On 26/02/21 1:37 am, Asutosh Das wrote: > During runtime-suspend of ufs host, the scsi devices are > already suspended and so are the queues associated with them. > But t

Re: [PATCH] mmc: Try power cycling card if command request times out

2021-03-01 Thread Adrian Hunter
On 1/03/21 10:50 am, Ulf Hansson wrote: > + Adrian > > On Tue, 16 Feb 2021 at 23:43, Mårten Lindahl wrote: >> >> Sometimes SD cards that has been run for a long time enters a state >> where it cannot by itself be recovered, but needs a power cycle to be >> operational again. Card status analysis

Re: [PATCH v7 1/2] scsi: ufs: Enable power management for wlun

2021-02-25 Thread Adrian Hunter
On 25/02/21 5:00 am, Asutosh Das wrote: > During runtime-suspend of ufs host, the scsi devices are > already suspended and so are the queues associated with them. > But the ufs host sends SSU to wlun during its runtime-suspend. > During the process blk_queue_enter checks if the queue is not in > su

Re: [PATCH v5 1/2] scsi: ufs: Enable power management for wlun

2021-02-24 Thread Adrian Hunter
On 24/02/21 7:13 am, Asutosh Das wrote: > During runtime-suspend of ufs host, the scsi devices are > already suspended and so are the queues associated with them. > But the ufs host sends SSU to wlun during its runtime-suspend. > During the process blk_queue_enter checks if the queue is not in > su

Re: [PATCH v4 1/2] scsi: ufs: Enable power management for wlun

2021-02-23 Thread Adrian Hunter
On 23/02/21 1:04 am, Asutosh Das wrote: > During runtime-suspend of ufs host, the scsi devices are > already suspended and so are the queues associated with them. > But the ufs host sends SSU to wlun during its runtime-suspend. > During the process blk_queue_enter checks if the queue is not in > su

Re: [RFC PATCH v3 1/1] scsi: ufs: Enable power management for wlun

2021-02-19 Thread Adrian Hunter
On 11/02/21 9:18 pm, Asutosh Das wrote: > During runtime-suspend of ufs host, the scsi devices are > already suspended and so are the queues associated with them. > But the ufs host sends SSU to wlun during its runtime-suspend. > During the process blk_queue_enter checks if the queue is not in > su

[PATCH 02/11] perf intel_pt: Add vmlaunch and vmresume as branches

2021-02-18 Thread Adrian Hunter
In preparation to support Intel PT decoding of virtual machine traces, add vmlaunch and vmresume as branch instructions. Note, sample flags will show "VMentry" even if the VM-Entry fails. Signed-off-by: Adrian Hunter --- tools/perf/arch/x86/tests/insn-x86.c | 1 + .../

  1   2   3   4   5   6   7   8   9   10   >