Page MenuHomeFreeBSD

efivar: support device paths as well as mounted paths in path_to_dp
ClosedPublic

Authored by imp on Feb 15 2023, 7:51 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sun, Nov 16, 8:52 PM
Unknown Object (File)
Sun, Nov 16, 3:36 PM
Unknown Object (File)
Sun, Nov 16, 12:44 AM
Unknown Object (File)
Fri, Nov 7, 10:21 PM
Unknown Object (File)
Thu, Oct 30, 10:56 PM
Unknown Object (File)
Thu, Oct 30, 8:03 AM
Unknown Object (File)
Wed, Oct 29, 8:04 PM
Unknown Object (File)
Mon, Oct 27, 1:13 PM
Subscribers
None

Details

Summary

In path_to_dp, allow passing in either the actual device path "eg
/dev/foo/bar" or the path where the device is mounted (say
/mnt/baz/bing). In the former case we'll assume the path within the
device is nothing (the relpath). In the latter, we'll take from the
mount point on down as the relpath.

Sponsored by: Netflix

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

imp requested review of this revision.Feb 15 2023, 7:51 PM
imp created this revision.

Is the purpose of this change to accept either a "/dev/foo/bar" or a "foo/bar"? Also, in your commit message could you check the word choice in "know the path passed in" ?

Is the purpose of this change to accept either a "/dev/foo/bar" or a "foo/bar"? Also, in your commit message could you check the word choice in "know the path passed in" ?

Not quite. The purpose of the change is to allow either /dev/foo/bar or /mnt/baz to be passed in.

I'll update the proposed commit message to see if my second attempt is any clearer.

asomers added inline comments.
lib/libefivar/efivar-dp-xlate.c
650–651

This comment is now out of date.

This revision is now accepted and ready to land.Feb 16 2023, 12:29 AM
This revision now requires review to proceed.Feb 16 2023, 12:40 AM
This revision is now accepted and ready to land.Feb 16 2023, 7:04 AM