- 22 Feb, 2017 4 commits
-
-
Jon Derrick authored
By embedding the function data with the function sequence, we can eliminate the external function data and state variable code. It also made obvious some other small cleanups. Signed-off-by:
Jon Derrick <jonathan.derrick@intel.com> Reviewed-by:
Scott Bauer <scott.bauer@intel.com> Signed-off-by:
Jens Axboe <axboe@fb.com>
-
Jon Derrick authored
Add a buffer size check against discovery and response header lengths before we loop over their buffers. Signed-off-by:
Jon Derrick <jonathan.derrick@intel.com> Reviewed-by:
Scott Bauer <scott.bauer@intel.com> Reviewed-by:
Christoph Hellwig <hch@lst.de> Signed-off-by:
Jens Axboe <axboe@fb.com>
-
Jon Derrick authored
Add helper which verifies the response token is valid and matches the expected value. Merges token_type and response_get_token. Signed-off-by:
Jon Derrick <jonathan.derrick@intel.com> Reviewed-by:
Scott Bauer <scott.bauer@intel.com> Reviewed-by:
Christoph Hellwig <hch@lst.de> Signed-off-by:
Jens Axboe <axboe@fb.com>
-
Jon Derrick authored
The short atom parser can return an errno from decoding but does not currently return the error as a signed value. Convert all of the parsers to ssize_t. Signed-off-by:
Jon Derrick <jonathan.derrick@intel.com> Reviewed-by:
Scott Bauer <scott.bauer@intel.com> Reviewed-by:
Christoph Hellwig <hch@lst.de> Signed-off-by:
Jens Axboe <axboe@fb.com>
-
- 17 Feb, 2017 2 commits
-
-
Christoph Hellwig authored
Insted of bloating the containing structure with it all the time this allocates struct opal_dev dynamically. Additionally this allows moving the definition of struct opal_dev into sed-opal.c. For this a new private data field is added to it that is passed to the send/receive callback. After that a lot of internals can be made private as well. Signed-off-by:
Christoph Hellwig <hch@lst.de> Tested-by:
Scott Bauer <scott.bauer@intel.com> Reviewed-by:
Scott Bauer <scott.bauer@intel.com> Signed-off-by:
Jens Axboe <axboe@fb.com>
-
Christoph Hellwig authored
Not having OPAL or a sub-feature supported is an entirely normal condition for many drives, so don't warn about it. Keep the messages, but tone them down to debug only. Signed-off-by:
Christoph Hellwig <hch@lst.de> Reviewed-by:
Scott Bauer <scott.bauer@intel.com> Signed-off-by:
Jens Axboe <axboe@fb.com>
-
- 15 Feb, 2017 1 commit
-
-
Scott Bauer authored
When CONFIG_KASAN is enabled, compilation fails: block/sed-opal.c: In function 'sed_ioctl': block/sed-opal.c:2447:1: error: the frame size of 2256 bytes is larger than 2048 bytes [-Werror=frame-larger-than=] Moved all the ioctl structures off the stack and dynamically allocate using _IOC_SIZE() Fixes: 455a7b23 ("block: Add Sed-opal library") Reported-by:
Arnd Bergmann <arnd@arndb.de> Signed-off-by:
Scott Bauer <scott.bauer@intel.com> Signed-off-by:
Jens Axboe <axboe@fb.com>
-
- 06 Feb, 2017 1 commit
-
-
Scott Bauer authored
This patch implements the necessary logic to bring an Opal enabled drive out of a factory-enabled into a working Opal state. This patch set also enables logic to save a password to be replayed during a resume from suspend. Signed-off-by:
Scott Bauer <scott.bauer@intel.com> Signed-off-by:
Rafael Antognolli <Rafael.Antognolli@intel.com> Reviewed-by:
Christoph Hellwig <hch@lst.de> Signed-off-by:
Jens Axboe <axboe@fb.com>
-