Page MenuHomeFreeBSD

lua loader: Auto detect eligible list of kernels to boot
ClosedPublic

Authored by cem on Feb 17 2018, 9:58 PM.
Tags
None
Referenced Files
F93529814: D14419.id39444.diff
Tue, Sep 10, 3:22 AM
Unknown Object (File)
Fri, Sep 6, 9:41 AM
Unknown Object (File)
Thu, Sep 5, 7:50 PM
Unknown Object (File)
Tue, Sep 3, 3:11 AM
Unknown Object (File)
Aug 3 2024, 10:56 PM
Unknown Object (File)
Jul 29 2024, 9:44 AM
Unknown Object (File)
Jul 15 2024, 1:35 AM
Unknown Object (File)
Jul 7 2024, 8:17 AM
Subscribers
None

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

This looks really cool!

stand/lua/core.lua
149 ↗(On Diff #39444)

How close / far from the standard lfs definition is this?

This revision is now accepted and ready to land.Feb 17 2018, 10:00 PM
In D14419#302195, @imp wrote:

This looks really cool!

Thanks!

stand/lua/core.lua
149 ↗(On Diff #39444)

lfs.dir() is identical, I think.

lfs.attributes() is slightly different in that we don't represent permissions as "drwxrwxrwx" and instead just dump an octal string out. That could be made more compliant if it's important.

(And: we're missing all APIs except those two.)

Otherwise, it should match the standard lfs exactly.

Looks good to me. =) Deduping the kernel listing was on my TODO list, along with fixing the module_path foo.

Looks good to me. =) Deduping the kernel listing was on my TODO list, along with fixing the module_path foo.

Thanks! I'm not sure I understand / did anything about module_path foo, can you elaborate a little?

In D14419#302234, @cem wrote:

Looks good to me. =) Deduping the kernel listing was on my TODO list, along with fixing the module_path foo.

Thanks! I'm not sure I understand / did anything about module_path foo, can you elaborate a little?

Nothing you've touched here, but a little further down [1] we add kernel directory to module_path, but we build off of getenv('module_path') and end up with multiple kernel directories in the path. Ideally we'd cache the module_path the first time and add the current kernel path to that every time.

https://svnweb.freebsd.org/base/head/stand/lua/config.lua?revision=329457&view=markup#l296

(while flipping through the kernel selector, that is)

Nothing you've touched here, but a little further down [1] we add kernel directory to module_path, but we build off of getenv('module_path') and end up with multiple kernel directories in the path. Ideally we'd cache the module_path the first time and add the current kernel path to that every time.

https://svnweb.freebsd.org/base/head/stand/lua/config.lua?revision=329457&view=markup#l296

Oh, ok. I'm going to leave that alone in this revision, if that's alright.

This revision was automatically updated to reflect the committed changes.