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)
Fri, Nov 8, 9:39 AM
Unknown Object (File)
Mon, Oct 28, 5:17 AM
Unknown Object (File)
Wed, Oct 23, 3:12 PM
Unknown Object (File)
Tue, Oct 22, 7:47 AM
Unknown Object (File)
Sun, Oct 20, 4:51 AM
Unknown Object (File)
Thu, Oct 17, 7:46 AM
Unknown Object (File)
Wed, Oct 16, 10:00 PM
Unknown Object (File)
Mon, Oct 14, 2:17 AM
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