Age | Commit message (Collapse) | Author |
|
|
|
|
|
already calls splvm as necessary.
ok mikeb@
|
|
ok krw@
|
|
simply allocate larger work units and include the normal work unit struct
in the top of the crypto work unit struct.
This greatly simplifies the code and removes possible failure cases.
Discussed with dlg@
ok krw@
|
|
ok krw@
|
|
already been checked in sr_crypto_alloc_resources and sr_validate_io.
Also document the known issue with per-block key selection.
ok krw@
|
|
algorithm.
|
|
instead of having multiple switch statements in various places.
ok mikeb@
|
|
|
|
anything.
ok mikeb@
|
|
ok jsing@
|
|
u_int32_t's with %u.
Translate DL_GETPSIZE() results to 512-byte-block values with
DL_SECTOBLK().
ok jsing@
|
|
can expose some of the kernel structures with split .h files if need be.
Discussed with various, including jsing.
|
|
test period; i think 3 years ago the last bugs fell out.
ok otto beck others
|
|
simplifies the discipline code, avoids code duplication and moves the
scheduling logic into a single location.
ok krw@
|
|
fact that it is used to generate I/O to the underlying device.
Input from/ok krw@
|
|
until disk I/O is performed. This avoids doing encryption for a write
that has an invalid I/O request. Additionally sr_crypto_wu_get() can
get the block number from the work unit, instead of decoding the SCSI
command (and failing to handle the invalid case).
ok krw@
|
|
provided.
|
|
implementations only ever returned zero. Change the return value from
int to void instead of pretending it might mean something.
|
|
the disciplines that now have the same interrupt code.
ok krw@
|
|
called. As a result, factor out the the sd_sync check/wakeup code and move
it to after the scsi_done() call in sr_scsi_done(). Perform the same
sd_sync check/wakeup after scsi_io_put() calls (including the addition of
some that were previously missed).
ok krw@
|
|
a valid struct sr_discipline. Remove redundant NULL pointer checks.
|
|
|
|
ok krw@
|
|
|
|
discipline data structure. To be used with an upcoming diff.
|
|
a crypto volume when it is assembling it.
|
|
during volume assembly.
|
|
size of 512 bytes - any other size is not currently supported.
ok krw@
|
|
to provide useful feedback, rather than reporting an ioctl failure and
leaving the user to consult dmesg. For now we continue to print most things
to the console, even if the message is a result of an ioctl.
|
|
from walking an uninitialised list if we fail to read the key disk.
|
|
cover the no redundancy/no rebuild case. Use these for the AOE, crypto and
RAID 0 disciplines.
|
|
those that are needed by a specific discipline.
|
|
are if used with a key disk.
|
|
of splitting and rejoining the list.
|
|
will allow new optional metadata types to be added without needing to
change the softraid metadata version.
Note that this commit changes the softraid metadata version, however
an upgrade from older metadata is handled automatically. A full backup
prior to upgrading is still strongly recommended.
With feedback from stsp@ and marco.
|
|
metadata handling code. This will simplify upcoming changes.
|
|
ok deraadt matthew
|
|
Instead of allocating a crypto op and the optional dma buffer on each
and every io, preallocate a list of softraid crypto wus that contain a
buffer of the max size we will use (MAXPHYS). since we know the number
of openings we have in advance this means that on each io we just pick
one, shorten the list of crypto descs, init any values then do the io.
ok jsing (who provided many useful comments. he also provided a smarter way of
handling the cryptop lists which is not in this diff but will be implemented
soonish), marco@.
dlg@ pointed out that this should probably use iopools but letting
disciplines allocate their own iopool involves more softraid rejigging
that will have to be done first. For now this is sufficient.
|
|
ok deraadt@
|
|
1) Allocating with M_WAITOK, checking for NULL, and calling panic() is
pointless (malloc() will panic if it can't allocate) so remove the check
and the call.
2) Allocating with M_WAITOK, checking for NULL, and then gracefully
handling failure to allocate is pointless. Instead also pass M_CANFAIL
so malloc() doesn't panic so we can actually handle it gracefully.
1) was done using Coccinelle.
Input from oga.
ok miod.
|
|
message if the key disk cannot be opened. ok marco (some time ago)
|
|
to panic if we couldn't allocate memory for crypto descriptors;
tested by dcoppa, ok marco
|
|
|
|
ok dlg@ marco@
|
|
|
|
|
|
ok marco
|
|
prodded and ok deraadt
|