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
Unknown Object (File)
Sat, Aug 3, 10:56 PM
Unknown Object (File)
Mon, Jul 29, 9:44 AM
Unknown Object (File)
Mon, Jul 15, 1:35 AM
Unknown Object (File)
Jul 7 2024, 8:17 AM
Unknown Object (File)
Jun 21 2024, 6:51 AM
Unknown Object (File)
Apr 15 2024, 5:32 AM
Unknown Object (File)
Feb 4 2024, 2:01 AM
Unknown Object (File)
Jan 9 2024, 4:30 AM
Subscribers
None

Diff Detail

Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 15121
Build 15214: arc lint + arc unit

Event Timeline

This looks really cool!

stand/lua/core.lua
149

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

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.