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
F156667581: D38616.id117349.diff
Fri, May 15, 1:26 PM
Unknown Object (File)
Thu, May 14, 12:39 PM
Unknown Object (File)
Thu, May 14, 4:38 AM
Unknown Object (File)
Fri, May 8, 8:18 PM
Unknown Object (File)
Fri, May 1, 10:30 PM
Unknown Object (File)
Wed, Apr 29, 11:28 AM
Unknown Object (File)
Tue, Apr 28, 9:34 AM
Unknown Object (File)
Tue, Apr 28, 9:21 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