mbox series

[HIRSUTE,linux-riscv,0/3] Disable ftrace of all sbi functions

Message ID 20210817162720.126460-1-dimitri.ledkov@canonical.com
Headers show
Series Disable ftrace of all sbi functions | expand

Message

Dimitri John Ledkov Aug. 17, 2021, 4:27 p.m. UTC
Cherry-pick upstream patches that correctly disable ftrace of all
sbi.c functions, thus preventing spurious failure to boot. One cannot
ftrace functions that are used in ftrace setup.

This has been fixed in v5.12, did not make into 5.11.x-stable which is
no longer stable upstream.

Our previous, incomplete fix, to disable ftrace on just one sbi
function call is thus no longer needed with these cherrypicks and can
be reverted, given that all sbi functions have tracing disabled with
these patches.

BugLink: https://bugs.launchpad.net/bugs/1934548

Dimitri John Ledkov (1):
  Revert "UBUNTU: SAUCE: RISC-V: prevent sbi_send_cpumask_ipi race with
    ftrace"

Guo Ren (2):
  riscv: Fixup wrong ftrace remove cflag
  riscv: Fixup patch_text panic in ftrace

 arch/riscv/kernel/Makefile | 5 +++--
 arch/riscv/kernel/sbi.c    | 2 +-
 arch/riscv/mm/Makefile     | 3 ++-
 3 files changed, 6 insertions(+), 4 deletions(-)

Comments

Tim Gardner Aug. 17, 2021, 5:41 p.m. UTC | #1
Acked-by: Tim Gardner <tim.gardner@canonical.com>

On 8/17/21 10:27 AM, Dimitri John Ledkov wrote:
> Cherry-pick upstream patches that correctly disable ftrace of all
> sbi.c functions, thus preventing spurious failure to boot. One cannot
> ftrace functions that are used in ftrace setup.
> 
> This has been fixed in v5.12, did not make into 5.11.x-stable which is
> no longer stable upstream.
> 
> Our previous, incomplete fix, to disable ftrace on just one sbi
> function call is thus no longer needed with these cherrypicks and can
> be reverted, given that all sbi functions have tracing disabled with
> these patches.
> 
> BugLink: https://bugs.launchpad.net/bugs/1934548
> 
> Dimitri John Ledkov (1):
>    Revert "UBUNTU: SAUCE: RISC-V: prevent sbi_send_cpumask_ipi race with
>      ftrace"
> 
> Guo Ren (2):
>    riscv: Fixup wrong ftrace remove cflag
>    riscv: Fixup patch_text panic in ftrace
> 
>   arch/riscv/kernel/Makefile | 5 +++--
>   arch/riscv/kernel/sbi.c    | 2 +-
>   arch/riscv/mm/Makefile     | 3 ++-
>   3 files changed, 6 insertions(+), 4 deletions(-)
>
Colin Ian King Aug. 17, 2021, 5:46 p.m. UTC | #2
On 17/08/2021 17:27, Dimitri John Ledkov wrote:
> Cherry-pick upstream patches that correctly disable ftrace of all
> sbi.c functions, thus preventing spurious failure to boot. One cannot
> ftrace functions that are used in ftrace setup.
> 
> This has been fixed in v5.12, did not make into 5.11.x-stable which is
> no longer stable upstream.
> 
> Our previous, incomplete fix, to disable ftrace on just one sbi
> function call is thus no longer needed with these cherrypicks and can
> be reverted, given that all sbi functions have tracing disabled with
> these patches.
> 
> BugLink: https://bugs.launchpad.net/bugs/1934548
> 
> Dimitri John Ledkov (1):
>   Revert "UBUNTU: SAUCE: RISC-V: prevent sbi_send_cpumask_ipi race with
>     ftrace"
> 
> Guo Ren (2):
>   riscv: Fixup wrong ftrace remove cflag
>   riscv: Fixup patch_text panic in ftrace
> 
>  arch/riscv/kernel/Makefile | 5 +++--
>  arch/riscv/kernel/sbi.c    | 2 +-
>  arch/riscv/mm/Makefile     | 3 ++-
>  3 files changed, 6 insertions(+), 4 deletions(-)
> 

Thanks Dimitri, this looks sane to me.  The bug link is missing a SRU
justification and list of risks with this fix. Care to update this?

Acked-by: Colin Ian King <colin.king@canonical.com>
Stefan Bader Aug. 18, 2021, 7:36 a.m. UTC | #3
On 17.08.21 18:27, Dimitri John Ledkov wrote:
> Cherry-pick upstream patches that correctly disable ftrace of all
> sbi.c functions, thus preventing spurious failure to boot. One cannot
> ftrace functions that are used in ftrace setup.
> 
> This has been fixed in v5.12, did not make into 5.11.x-stable which is
> no longer stable upstream.
> 
> Our previous, incomplete fix, to disable ftrace on just one sbi
> function call is thus no longer needed with these cherrypicks and can
> be reverted, given that all sbi functions have tracing disabled with
> these patches.
> 
> BugLink: https://bugs.launchpad.net/bugs/1934548

All patches are missing the BugLink and you cannot re-use above bug report. That 
is already committed and there would be no sane way to track that the follow-up 
things are applied.

-Stefan

> 
> Dimitri John Ledkov (1):
>    Revert "UBUNTU: SAUCE: RISC-V: prevent sbi_send_cpumask_ipi race with
>      ftrace"
> 
> Guo Ren (2):
>    riscv: Fixup wrong ftrace remove cflag
>    riscv: Fixup patch_text panic in ftrace
> 
>   arch/riscv/kernel/Makefile | 5 +++--
>   arch/riscv/kernel/sbi.c    | 2 +-
>   arch/riscv/mm/Makefile     | 3 ++-
>   3 files changed, 6 insertions(+), 4 deletions(-)
>
Dimitri John Ledkov Aug. 18, 2021, 11:48 a.m. UTC | #4
will resubmit with redone paperwork.

On Tue, Aug 17, 2021 at 5:27 PM Dimitri John Ledkov
<dimitri.ledkov@canonical.com> wrote:
>
> Cherry-pick upstream patches that correctly disable ftrace of all
> sbi.c functions, thus preventing spurious failure to boot. One cannot
> ftrace functions that are used in ftrace setup.
>
> This has been fixed in v5.12, did not make into 5.11.x-stable which is
> no longer stable upstream.
>
> Our previous, incomplete fix, to disable ftrace on just one sbi
> function call is thus no longer needed with these cherrypicks and can
> be reverted, given that all sbi functions have tracing disabled with
> these patches.
>
> BugLink: https://bugs.launchpad.net/bugs/1934548
>
> Dimitri John Ledkov (1):
>   Revert "UBUNTU: SAUCE: RISC-V: prevent sbi_send_cpumask_ipi race with
>     ftrace"
>
> Guo Ren (2):
>   riscv: Fixup wrong ftrace remove cflag
>   riscv: Fixup patch_text panic in ftrace
>
>  arch/riscv/kernel/Makefile | 5 +++--
>  arch/riscv/kernel/sbi.c    | 2 +-
>  arch/riscv/mm/Makefile     | 3 ++-
>  3 files changed, 6 insertions(+), 4 deletions(-)
>
> --
> 2.30.2
>