linux/drivers/misc/mic/scif/scif_rma_list.h
Thomas Gleixner 1802d0beec treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 174
Based on 1 normalized pattern(s):

  this program is free software you can redistribute it and or modify
  it under the terms of the gnu general public license version 2 as
  published by the free software foundation this program is
  distributed in the hope that it will be useful but without any
  warranty without even the implied warranty of merchantability or
  fitness for a particular purpose see the gnu general public license
  for more details

extracted by the scancode license scanner the SPDX license identifier

  GPL-2.0-only

has been chosen to replace the boilerplate/reference in 655 file(s).

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Allison Randal <allison@lohutok.net>
Reviewed-by: Kate Stewart <kstewart@linuxfoundation.org>
Reviewed-by: Richard Fontana <rfontana@redhat.com>
Cc: linux-spdx@vger.kernel.org
Link: https://lkml.kernel.org/r/20190527070034.575739538@linutronix.de
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-05-30 11:26:41 -07:00

49 lines
1.4 KiB
C

/* SPDX-License-Identifier: GPL-2.0-only */
/*
* Intel MIC Platform Software Stack (MPSS)
*
* Copyright(c) 2015 Intel Corporation.
*
* Intel SCIF driver.
*/
#ifndef SCIF_RMA_LIST_H
#define SCIF_RMA_LIST_H
/*
* struct scif_rma_req - Self Registration list RMA Request query
*
* @out_window - Returns the window if found
* @offset: Starting offset
* @nr_bytes: number of bytes
* @prot: protection requested i.e. read or write or both
* @type: Specify single, partial or multiple windows
* @head: Head of list on which to search
* @va_for_temp: VA for searching temporary cached windows
*/
struct scif_rma_req {
struct scif_window **out_window;
union {
s64 offset;
unsigned long va_for_temp;
};
size_t nr_bytes;
int prot;
enum scif_window_type type;
struct list_head *head;
};
/* Insert */
void scif_insert_window(struct scif_window *window, struct list_head *head);
void scif_insert_tcw(struct scif_window *window,
struct list_head *head);
/* Query */
int scif_query_window(struct scif_rma_req *request);
int scif_query_tcw(struct scif_endpt *ep, struct scif_rma_req *request);
/* Called from close to unregister all self windows */
int scif_unregister_all_windows(scif_epd_t epd);
void scif_unmap_all_windows(scif_epd_t epd);
/* Traverse list and unregister */
int scif_rma_list_unregister(struct scif_window *window, s64 offset,
int nr_pages);
#endif /* SCIF_RMA_LIST_H */