• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 #include "headers.h"
2 /*
3  * Procedure:	vendorextnGetSectionInfo
4  *
5  * Description: Finds the type of NVM used.
6  *
7  * Arguments:
8  *		Adapter    - ptr to Adapter object instance
9  *		pNVMType   - ptr to NVM type.
10  * Returns:
11  *		STATUS_SUCCESS/STATUS_FAILURE
12  *
13  */
vendorextnGetSectionInfo(PVOID pContext,struct bcm_flash2x_vendor_info * pVendorInfo)14 INT vendorextnGetSectionInfo(PVOID  pContext,
15 			struct bcm_flash2x_vendor_info *pVendorInfo)
16 {
17 	return STATUS_FAILURE;
18 }
19 
20 /*
21  * Procedure:   vendorextnInit
22  *
23  * Description: Initializing the vendor extension NVM interface
24  *
25  * Arguments:
26  *              Adapter   - Pointer to MINI Adapter Structure
27  * Returns:
28  *             STATUS_SUCCESS/STATUS_FAILURE
29  *
30  *
31  */
vendorextnInit(struct bcm_mini_adapter * Adapter)32 INT vendorextnInit(struct bcm_mini_adapter *Adapter)
33 {
34 	return STATUS_SUCCESS;
35 }
36 
37 /*
38  * Procedure:   vendorextnExit
39  *
40  * Description: Free the resource associated with vendor extension NVM interface
41  *
42  * Arguments:
43  *
44  * Returns:
45  *              STATUS_SUCCESS/STATUS_FAILURE
46  *
47  *
48  */
vendorextnExit(struct bcm_mini_adapter * Adapter)49 INT vendorextnExit(struct bcm_mini_adapter *Adapter)
50 {
51 	return STATUS_SUCCESS;
52 }
53 
54 /*
55  * Procedure:	vendorextnIoctl
56  *
57  * Description: execute the vendor extension specific ioctl
58  *
59  * Arguments:
60  *		Adapter -Beceem private Adapter Structure
61  *		cmd	-vendor extension specific Ioctl commad
62  *		arg	-input parameter sent by vendor
63  *
64  * Returns:
65  *		CONTINUE_COMMON_PATH in case it is not meant to be processed
66  *		by vendor ioctls
67  *		STATUS_SUCCESS/STATUS_FAILURE as per the IOCTL return value
68  */
69 
vendorextnIoctl(struct bcm_mini_adapter * Adapter,UINT cmd,ULONG arg)70 INT vendorextnIoctl(struct bcm_mini_adapter *Adapter, UINT cmd, ULONG arg)
71 {
72 	return CONTINUE_COMMON_PATH;
73 }
74 
75 
76 
77 /*
78  * Procedure:	vendorextnReadSection
79  *
80  * Description: Reads from a section of NVM
81  *
82  * Arguments:
83  *		pContext - ptr to Adapter object instance
84  *		pBuffer - Read the data from Vendor Area to this buffer
85  *		SectionVal   - Value of type of Section
86  *		Offset - Read from the Offset of the Vendor Section.
87  *		numOfBytes - Read numOfBytes from the Vendor section to Buffer
88  *
89  * Returns:
90  *		STATUS_SUCCESS/STATUS_FAILURE
91  */
92 
vendorextnReadSection(PVOID pContext,PUCHAR pBuffer,enum bcm_flash2x_section_val SectionVal,UINT offset,UINT numOfBytes)93 INT vendorextnReadSection(PVOID  pContext, PUCHAR pBuffer,
94 	enum bcm_flash2x_section_val SectionVal, UINT offset, UINT numOfBytes)
95 {
96 	return STATUS_FAILURE;
97 }
98 
99 
100 
101 /*
102  * Procedure:	vendorextnWriteSection
103  *
104  * Description: Write to a Section of NVM
105  *
106  * Arguments:
107  *		pContext - ptr to Adapter object instance
108  *		pBuffer - Write the data provided in the buffer
109  *		SectionVal   - Value of type of Section
110  *		Offset - Writes to the Offset of the Vendor Section.
111  *		numOfBytes - Write num Bytes after reading from pBuffer.
112  *		bVerify - the Buffer Written should be verified.
113  *
114  * Returns:
115  *		STATUS_SUCCESS/STATUS_FAILURE
116  */
vendorextnWriteSection(PVOID pContext,PUCHAR pBuffer,enum bcm_flash2x_section_val SectionVal,UINT offset,UINT numOfBytes,bool bVerify)117 INT vendorextnWriteSection(PVOID  pContext, PUCHAR pBuffer,
118 	enum bcm_flash2x_section_val SectionVal, UINT offset,
119 	UINT numOfBytes, bool bVerify)
120 {
121 	return STATUS_FAILURE;
122 }
123 
124 
125 
126 /*
127  * Procedure:	vendorextnWriteSectionWithoutErase
128  *
129  * Description: Write to a Section of NVM without erasing the sector
130  *
131  * Arguments:
132  *		pContext - ptr to Adapter object instance
133  *		pBuffer - Write the data provided in the buffer
134  *		SectionVal   - Value of type of Section
135  *		Offset - Writes to the Offset of the Vendor Section.
136  *		numOfBytes - Write num Bytes after reading from pBuffer.
137  *
138  * Returns:
139  *		STATUS_SUCCESS/STATUS_FAILURE
140  */
vendorextnWriteSectionWithoutErase(PVOID pContext,PUCHAR pBuffer,enum bcm_flash2x_section_val SectionVal,UINT offset,UINT numOfBytes)141 INT vendorextnWriteSectionWithoutErase(PVOID  pContext, PUCHAR pBuffer,
142 	enum bcm_flash2x_section_val SectionVal, UINT offset, UINT numOfBytes)
143 {
144 	return STATUS_FAILURE;
145 }
146