[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <964def29d1e146fc8ac17ab2fe813425@EXMBX161.cuchost.com>
Date: Tue, 10 Jan 2023 03:16:37 +0000
From: Leyfoon Tan <leyfoon.tan@...rfivetech.com>
To: Andrew Jones <ajones@...tanamicro.com>,
JeeHeng Sia <jeeheng.sia@...rfivetech.com>
CC: "paul.walmsley@...ive.com" <paul.walmsley@...ive.com>,
"palmer@...belt.com" <palmer@...belt.com>,
"aou@...s.berkeley.edu" <aou@...s.berkeley.edu>,
"linux-riscv@...ts.infradead.org" <linux-riscv@...ts.infradead.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
Mason Huo <mason.huo@...rfivetech.com>
Subject: RE: [PATCH v2 3/3] RISC-V: Add arch functions to support
hibernation/suspend-to-disk
[...]
>
> > +{
> > + hibernate_cpu_context = kcalloc(1, sizeof(struct suspend_context),
> GFP_KERNEL);
> > +
> > + if (WARN_ON(!hibernate_cpu_context))
> > + return -ENOMEM;
> > +
> > + return 0;
> > +}
> > +
> > +early_initcall(riscv_hibernate__init);
> > --
> > 2.34.1
> >
> >
>
> Besides some nits and a couple questions, this looks to me. I'll try to
> find some time to experiment with it as well.
FYI, you need use the latest OpenSBI tree. We also submitted these 2 patches below to fix the boot hartid. Resume from hibernation needs to be same hartid.
https://github.com/riscv-software-src/opensbi/commit/cb7e7c3325e68a9b4d5ea210b97cac693cf5814f
https://github.com/riscv-software-src/opensbi/commit/8020df8733b060f01e35b0b2bcb2b41e6b992e9b
Powered by blists - more mailing lists