Switchtec Userspace
PROJECT_NUMBER = 4.2
Toggle main menu visibility
Loading...
Searching...
No Matches
lib
platform
gasops.h
1
/*
2
* Microsemi Switchtec(tm) PCIe Management Library
3
* Copyright (c) 2017, Microsemi Corporation
4
*
5
* Permission is hereby granted, free of charge, to any person obtaining a
6
* copy of this software and associated documentation files (the "Software"),
7
* to deal in the Software without restriction, including without limitation
8
* the rights to use, copy, modify, merge, publish, distribute, sublicense,
9
* and/or sell copies of the Software, and to permit persons to whom the
10
* Software is furnished to do so, subject to the following conditions:
11
*
12
* The above copyright notice and this permission notice shall be included
13
* in all copies or substantial portions of the Software.
14
*
15
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
16
* OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
18
* THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR
19
* OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
20
* ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
21
* OTHER DEALINGS IN THE SOFTWARE.
22
*
23
*/
24
25
#ifndef LIBSWITCHTEC_GASOPS_H
26
#define LIBSWITCHTEC_GASOPS_H
27
28
#include "
switchtec/switchtec.h
"
29
#include "../switchtec_priv.h"
30
31
int
gasop_access_check(
struct
switchtec_dev *dev);
32
void
gasop_set_partition_info(
struct
switchtec_dev *dev);
33
int
gasop_cmd(
struct
switchtec_dev *dev, uint32_t cmd,
34
const
void
*payload,
size_t
payload_len,
void
*resp,
35
size_t
resp_len);
36
int
gasop_get_device_id(
struct
switchtec_dev *dev);
37
int
gasop_get_fw_version(
struct
switchtec_dev *dev,
char
*buf,
38
size_t
buflen);
39
int
gasop_get_device_version(
struct
switchtec_dev *dev,
int
*res);
40
int
gasop_pff_to_port(
struct
switchtec_dev *dev,
int
pff,
41
int
*partition,
int
*port);
42
int
gasop_port_to_pff(
struct
switchtec_dev *dev,
int
partition,
43
int
port,
int
*pff);
44
int
gasop_flash_part(
struct
switchtec_dev *dev,
45
struct
switchtec_fw_image_info
*info,
46
enum
switchtec_fw_image_part_id_gen3 part);
47
int
gasop_event_summary(
struct
switchtec_dev *dev,
48
struct
switchtec_event_summary
*sum);
49
int
gasop_event_ctl(
struct
switchtec_dev *dev,
enum
switchtec_event_id
e,
50
int
index,
int
flags, uint32_t data[5]);
51
int
gasop_event_wait_for(
struct
switchtec_dev *dev,
52
enum
switchtec_event_id
e,
int
index,
53
struct
switchtec_event_summary
*res,
54
int
timeout_ms);
55
56
#endif
switchtec_event_summary
Event summary bitmaps.
Definition
switchtec.h:308
switchtec_fw_image_info
Information about a firmware image or partition.
Definition
switchtec.h:270
switchtec.h
Main Switchtec header.
switchtec_event_id
switchtec_event_id
Enumeration of all possible events.
Definition
switchtec.h:323
Generated by
1.17.0