summaryrefslogtreecommitdiff
path: root/include/linux/pstore.h
diff options
context:
space:
mode:
authorKees Cook <keescook@chromium.org>2017-03-05 11:27:54 +0300
committerKees Cook <keescook@chromium.org>2017-03-08 01:01:01 +0300
commitb10b471145f28c219d9ddcc309a67e053776865a (patch)
tree9c59af1b2a6ef23b7fd36dbdc1a99b56d47d45f2 /include/linux/pstore.h
parenta61072aae693ba08390f92eed1dd0573fa5c3cd9 (diff)
downloadlinux-b10b471145f28c219d9ddcc309a67e053776865a.tar.xz
pstore: Replace arguments for write_buf() API
As with the other API updates, this removes the long argument list in favor of passing a single pstore recaord. Signed-off-by: Kees Cook <keescook@chromium.org>
Diffstat (limited to 'include/linux/pstore.h')
-rw-r--r--include/linux/pstore.h21
1 files changed, 5 insertions, 16 deletions
diff --git a/include/linux/pstore.h b/include/linux/pstore.h
index 2cd1979d1f9a..cbf5e561778d 100644
--- a/include/linux/pstore.h
+++ b/include/linux/pstore.h
@@ -142,19 +142,11 @@ struct pstore_record {
* Returns 0 on success, and non-zero on error.
*
* @write_buf:
- * Perform a frontend write to a backend record, using a specified
- * buffer. Unlike @write, this does not use the @psi @buf.
+ * Perform a frontend write to a backend record. The record contains
+ * all metadata and the buffer to write to backend storage. (Unlike
+ * @write, this does not use the @psi @buf.)
*
- * @type: in: pstore record type to write
- * @reason:
- * in: pstore write reason
- * @id: out: unique identifier for the record
- * @part: in: position in a multipart write
- * @buf: in: pointer to contents to write to backend record
- * @compressed:
- * in: if the record is compressed
- * @size: in: size of the write
- * @psi: in: pointer to the struct pstore_info for the backend
+ * @record: pointer to record metadata.
*
* Returns 0 on success, and non-zero on error.
*
@@ -203,10 +195,7 @@ struct pstore_info {
int (*close)(struct pstore_info *psi);
ssize_t (*read)(struct pstore_record *record);
int (*write)(struct pstore_record *record);
- int (*write_buf)(enum pstore_type_id type,
- enum kmsg_dump_reason reason, u64 *id,
- unsigned int part, const char *buf, bool compressed,
- size_t size, struct pstore_info *psi);
+ int (*write_buf)(struct pstore_record *record);
int (*write_buf_user)(enum pstore_type_id type,
enum kmsg_dump_reason reason, u64 *id,
unsigned int part, const char __user *buf,