FreeBSD Bugzilla – Attachment 154855 Details for
Bug 198863
[patch] geli: TRIM passthru
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch to swapon for fstab auto-ELI
swapon-geli-delete.patch (text/plain), 1.55 KB, created by
fullermd
on 2015-03-27 10:47:48 UTC
(
hide
)
Description:
Patch to swapon for fstab auto-ELI
Filename:
MIME Type:
Creator:
fullermd
Created:
2015-03-27 10:47:48 UTC
Size:
1.55 KB
patch
obsolete
>Index: sbin/swapon/swapon.c >=================================================================== >--- sbin/swapon/swapon.c (revision 279210) >+++ sbin/swapon/swapon.c (working copy) >@@ -313,7 +313,7 @@ > swap_on_geli_args(const char *mntops) > { > const char *aalgo, *ealgo, *keylen_str, *sectorsize_str; >- const char *aflag, *eflag, *lflag, *sflag; >+ const char *aflag, *eflag, *lflag, *tflag, *sflag; > char *p, *args, *token, *string, *ops; > int argsize, pagesize; > size_t pagesize_len; >@@ -321,7 +321,7 @@ > > /* Use built-in defaults for geli(8). */ > aalgo = ealgo = keylen_str = ""; >- aflag = eflag = lflag = ""; >+ aflag = eflag = lflag = tflag = ""; > > /* We will always specify sectorsize. */ > sflag = " -s "; >@@ -365,6 +365,8 @@ > free(ops); > return (NULL); > } >+ } else if ((p = strstr(token, "trim")) == token) { >+ tflag = " -t "; > } else if (strcmp(token, "sw") != 0) { > warnx("Invalid option: %s", token); > free(ops); >@@ -387,8 +389,8 @@ > sectorsize_str = p; > } > >- argsize = asprintf(&args, "%s%s%s%s%s%s%s%s -d", >- aflag, aalgo, eflag, ealgo, lflag, keylen_str, >+ argsize = asprintf(&args, "%s%s%s%s%s%s%s%s%s -d", >+ aflag, aalgo, eflag, ealgo, lflag, keylen_str, tflag, > sflag, sectorsize_str); > > free(ops); >Index: share/man/man5/fstab.5 >=================================================================== >--- share/man/man5/fstab.5 (revision 279210) >+++ share/man/man5/fstab.5 (working copy) >@@ -242,6 +242,7 @@ > .Dq ealgo , > .Dq aalgo , > .Dq keylen , >+.Dq trim , > and > .Dq sectorsize > options may be passed to control those
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 198863
:
154746
|
154855
|
156615
|
158599
|
158601