Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F106979071
D12340.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
683 B
Referenced Files
None
Subscribers
None
D12340.diff
View Options
Index: head/sys/boot/efi/libefi/efipart.c
===================================================================
--- head/sys/boot/efi/libefi/efipart.c
+++ head/sys/boot/efi/libefi/efipart.c
@@ -723,9 +723,20 @@
pd->pd_bcache = bcache_allocate();
if (dev->d_dev->dv_type == DEVT_DISK) {
- return (disk_open(dev,
+ int rc;
+
+ rc = disk_open(dev,
blkio->Media->BlockSize * (blkio->Media->LastBlock + 1),
- blkio->Media->BlockSize));
+ blkio->Media->BlockSize);
+ if (rc != 0) {
+ pd->pd_open--;
+ if (pd->pd_open == 0) {
+ pd->pd_blkio = NULL;
+ bcache_free(pd->pd_bcache);
+ pd->pd_bcache = NULL;
+ }
+ }
+ return (rc);
}
return (0);
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Thu, Jan 9, 10:38 AM (4 h, 59 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
15731763
Default Alt Text
D12340.diff (683 B)
Attached To
Mode
D12340: libefi: efipart_open should check the status from disk_open
Attached
Detach File
Event Timeline
Log In to Comment