Open Ethernet Networking (OpEN) API Guide and Reference Manual  3.9.0.2
openapi_logging.h
Go to the documentation of this file.
1 
9 /*********************************************************************
10 *
11 * Copyright 2016-2018 Broadcom.
12 *
13 * Licensed under the Apache License, Version 2.0 (the "License");
14 * you may not use this file except in compliance with the License.
15 * You may obtain a copy of the License at
16 *
17 * http://www.apache.org/licenses/LICENSE-2.0
18 *
19 * Unless required by applicable law or agreed to in writing, software
20 * distributed under the License is distributed on an "AS IS" BASIS,
21 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
22 * See the License for the specific language governing permissions and
23 * limitations under the License.
24 *
25 **********************************************************************
26 *
27 * @filename openapi_logging.h
28 *
29 * @purpose Logging Configuration and Status
30 *
31 * @component OpEN
32 *
33 * @create 28/01/2013
34 *
35 * @end
36 *
37 **********************************************************************/
38 #ifndef OPENAPI_LOGGING_H_INCLUDED
39 #define OPENAPI_LOGGING_H_INCLUDED
40 
41 #include "openapi_common.h"
42 
44 typedef enum
45 {
57 
58 #define OPENAPI_LOG_FORMAT_BUF_SIZE 512
59 
60 #define OPENAPI_LOG_ENTRY_BUF_SIZE (OPENAPI_LOG_FORMAT_BUF_SIZE + 80)
61 
62 #define OPENAPI_TRAP_ENTRY_SIZE (300)
63 
64 typedef struct
65 {
66  char trapEntry[OPENAPI_TRAP_ENTRY_SIZE];
68 
69 #define OPENAPI_TRAP_LOG_BUF_SIZE (256 * sizeof(openapiTrapLogEntry_t))
70 
71 
72 /*****************************************************************/
87  OPEN_CONTROL_t cmdLoggingMode);
88 
89 /*****************************************************************/
104  OPEN_CONTROL_t *cmdLoggingMode);
105 
106 /*****************************************************************/
122  OPEN_CONTROL_t loggingConsoleMode);
123 
124 /*****************************************************************/
139  OPEN_CONTROL_t *loggingConsoleMode);
140 
141 /*****************************************************************/
159  OPEN_LOG_SEVERITY_t severityLevel);
160 
161 /*****************************************************************/
176  OPEN_LOG_SEVERITY_t *severityLevel);
177 
178 /*****************************************************************/
195  OPEN_CONTROL_t persistentLoggingMode);
196 
197 /*****************************************************************/
215  OPEN_LOG_SEVERITY_t severityLevel);
216 
217 /*****************************************************************/
233  OPEN_CONTROL_t *loggingPersistentMode);
234 
235 /*****************************************************************/
251  OPEN_LOG_SEVERITY_t *severityLevel);
252 
253 /*****************************************************************/
269  OPEN_CONTROL_t sysLogMode);
270 
271 /*****************************************************************/
286  OPEN_CONTROL_t *sysLogMode);
287 
288 /*****************************************************************/
307  uint32_t port);
308 
309 /*****************************************************************/
324  uint16_t *port);
325 
326 /*****************************************************************/
350  open_buffdesc *loggingHost);
351 
352 /*****************************************************************/
375  open_buffdesc *loggingHost, uint32_t port);
376 
377 /*****************************************************************/
399  open_buffdesc *loggingHost,
400  OPEN_LOG_SEVERITY_t severityLevel);
401 
402 /*****************************************************************/
421  open_buffdesc *loggingHost);
422 
423 /*****************************************************************/
441  open_buffdesc *loggingHost,
442  OPEN_LOG_SEVERITY_t *severityLevel);
443 
444 /*****************************************************************/
462  open_buffdesc *loggingHost,
463  uint16_t *port);
464 
465 /*****************************************************************/
484  open_buffdesc *loggingHost);
485 
486 /*****************************************************************/
500  uint32_t *maxLoggingHosts);
501 
502 /*****************************************************************/
517  uint32_t *logHostMaxAddrLen);
518 
519 /*****************************************************************/
537  open_buffdesc *logMessage,
538  OPEN_LOG_SEVERITY_t severityLevel);
539 
540 /*****************************************************************/
564 open_error_t openapiBufferedLogEntryNextGet(openapiClientHandle_t *client_handle, uint32_t *logIndex,
565  open_buffdesc *logEntry);
566 
567 /*****************************************************************/
580 
581 /*****************************************************************/
597  uint32_t *numberOfEntries);
598 
599 /*****************************************************************/
612 
613 #endif
614