• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /* Generated by ./xlat/gen.sh from ./xlat/sg_scsi_reset.in; do not edit. */
2 
3 #include "gcc_compat.h"
4 #include "static_assert.h"
5 
6 #if defined(SG_SCSI_RESET_NOTHING) || (defined(HAVE_DECL_SG_SCSI_RESET_NOTHING) && HAVE_DECL_SG_SCSI_RESET_NOTHING)
7 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
8 static_assert((SG_SCSI_RESET_NOTHING) == (0), "SG_SCSI_RESET_NOTHING != 0");
9 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
10 #else
11 # define SG_SCSI_RESET_NOTHING 0
12 #endif
13 #if defined(SG_SCSI_RESET_DEVICE) || (defined(HAVE_DECL_SG_SCSI_RESET_DEVICE) && HAVE_DECL_SG_SCSI_RESET_DEVICE)
14 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
15 static_assert((SG_SCSI_RESET_DEVICE) == (1), "SG_SCSI_RESET_DEVICE != 1");
16 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
17 #else
18 # define SG_SCSI_RESET_DEVICE 1
19 #endif
20 #if defined(SG_SCSI_RESET_BUS) || (defined(HAVE_DECL_SG_SCSI_RESET_BUS) && HAVE_DECL_SG_SCSI_RESET_BUS)
21 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
22 static_assert((SG_SCSI_RESET_BUS) == (2), "SG_SCSI_RESET_BUS != 2");
23 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
24 #else
25 # define SG_SCSI_RESET_BUS 2
26 #endif
27 #if defined(SG_SCSI_RESET_HOST) || (defined(HAVE_DECL_SG_SCSI_RESET_HOST) && HAVE_DECL_SG_SCSI_RESET_HOST)
28 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
29 static_assert((SG_SCSI_RESET_HOST) == (3), "SG_SCSI_RESET_HOST != 3");
30 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
31 #else
32 # define SG_SCSI_RESET_HOST 3
33 #endif
34 #if defined(SG_SCSI_RESET_TARGET) || (defined(HAVE_DECL_SG_SCSI_RESET_TARGET) && HAVE_DECL_SG_SCSI_RESET_TARGET)
35 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
36 static_assert((SG_SCSI_RESET_TARGET) == (4), "SG_SCSI_RESET_TARGET != 4");
37 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
38 #else
39 # define SG_SCSI_RESET_TARGET 4
40 #endif
41 #if defined(SG_SCSI_RESET_NO_ESCALATE) || (defined(HAVE_DECL_SG_SCSI_RESET_NO_ESCALATE) && HAVE_DECL_SG_SCSI_RESET_NO_ESCALATE)
42 DIAG_PUSH_IGNORE_TAUTOLOGICAL_COMPARE
43 static_assert((SG_SCSI_RESET_NO_ESCALATE) == (0x100), "SG_SCSI_RESET_NO_ESCALATE != 0x100");
44 DIAG_POP_IGNORE_TAUTOLOGICAL_COMPARE
45 #else
46 # define SG_SCSI_RESET_NO_ESCALATE 0x100
47 #endif
48 
49 #ifndef XLAT_MACROS_ONLY
50 
51 # ifdef IN_MPERS
52 
53 #  error static const struct xlat sg_scsi_reset in mpers mode
54 
55 # else
56 
57 static
58 const struct xlat sg_scsi_reset[] = {
59  XLAT(SG_SCSI_RESET_NOTHING),
60  XLAT(SG_SCSI_RESET_DEVICE),
61  XLAT(SG_SCSI_RESET_BUS),
62  XLAT(SG_SCSI_RESET_HOST),
63  XLAT(SG_SCSI_RESET_TARGET),
64  XLAT(SG_SCSI_RESET_NO_ESCALATE),
65  XLAT_END
66 };
67 
68 # endif /* !IN_MPERS */
69 
70 #endif /* !XLAT_MACROS_ONLY */
71