Print this page
fixup .text where possible
7127  remove -Wno-missing-braces from Makefile.uts

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/common/crypto/io/ecc.c
          +++ new/usr/src/uts/common/crypto/io/ecc.c
↓ open down ↓ 54 lines elided ↑ open up ↑
  55   55  /*
  56   56   * Module linkage information for the kernel.
  57   57   */
  58   58  static struct modlcrypto modlcrypto = {
  59   59          &mod_cryptoops,
  60   60          "EC Kernel SW Provider"
  61   61  };
  62   62  
  63   63  static struct modlinkage modlinkage = {
  64   64          MODREV_1,
  65      -        (void *)&modlcrypto,
  66      -        NULL
       65 +        {   (void *)&modlcrypto,
       66 +            NULL }
  67   67  };
  68   68  
  69   69  /*
  70   70   * CSPI information (entry points, provider info, etc.)
  71   71   */
  72   72  typedef enum ecc_mech_type {
  73   73          EC_KEY_PAIR_GEN_MECH_INFO_TYPE, /* SUN_CKM_EC_KEY_PAIR_GEN */
  74   74          ECDSA_MECH_INFO_TYPE,           /* SUN_CKM_ECDSA */
  75   75          ECDSA_SHA1_MECH_INFO_TYPE,      /* SUN_CKM_ECDSA_SHA1 */
  76   76          ECDH1_DERIVE_MECH_INFO_TYPE     /* SUN_CKM_ECDH1_DERIVE */
↓ open down ↓ 107 lines elided ↑ open up ↑
 184  184      crypto_session_id_t, crypto_mechanism_t *, crypto_key_t *,
 185  185      crypto_object_attribute_t *, uint_t, crypto_object_attribute_t *,
 186  186      uint_t, crypto_req_handle_t);
 187  187  
 188  188  static crypto_nostore_key_ops_t ecc_nostore_key_ops = {
 189  189          NULL,
 190  190          ecc_nostore_key_generate_pair,
 191  191          ecc_nostore_key_derive
 192  192  };
 193  193  
 194      -static crypto_ops_t ecc_crypto_ops = {
 195      -        &ecc_control_ops,
 196      -        NULL,
 197      -        NULL,
 198      -        NULL,
 199      -        &ecc_sign_ops,
 200      -        &ecc_verify_ops,
 201      -        NULL,
 202      -        NULL,
 203      -        NULL,
 204      -        NULL,
 205      -        NULL,
 206      -        NULL,
 207      -        NULL,
 208      -        NULL,
 209      -        NULL,
 210      -        &ecc_nostore_key_ops,
 211      -        NULL,
 212      -};
      194 +static crypto_ops_t ecc_crypto_ops = {{{{{{
      195 +                                &ecc_control_ops,
      196 +                                NULL,
      197 +                                NULL,
      198 +                                NULL,
      199 +                                &ecc_sign_ops,
      200 +                                &ecc_verify_ops,
      201 +                                NULL,
      202 +                                NULL,
      203 +                                NULL,
      204 +                                NULL,
      205 +                                NULL,
      206 +                                NULL,
      207 +                                NULL,
      208 +                                NULL }, /* cou_v1 */
      209 +                        NULL },         /* cou_v2 */
      210 +                &ecc_nostore_key_ops }, /* cou_v3 */
      211 +        NULL },                         /* cou_v4 */
      212 +}};
 213  213  
 214      -static crypto_provider_info_t ecc_prov_info = {
      214 +static crypto_provider_info_t ecc_prov_info = {{{{
 215  215          CRYPTO_SPI_VERSION_4,
 216  216          "EC Software Provider",
 217  217          CRYPTO_SW_PROVIDER,
 218  218          {&modlinkage},
 219  219          NULL,
 220  220          &ecc_crypto_ops,
 221  221          sizeof (ecc_mech_info_tab)/sizeof (crypto_mech_info_t),
 222  222          ecc_mech_info_tab
 223      -};
      223 +}}}};
 224  224  
 225  225  static crypto_kcf_provider_handle_t ecc_prov_handle = NULL;
 226  226  
 227  227  static int ecc_sign_common(ecc_ctx_t *, crypto_data_t *, crypto_data_t *,
 228  228      crypto_req_handle_t);
 229  229  static int ecc_verify_common(ecc_ctx_t *, crypto_data_t *, crypto_data_t *,
 230  230      crypto_req_handle_t);
 231  231  static int find_attr(crypto_object_attribute_t *, uint_t, uint64_t);
 232  232  static int get_template_attr_ulong(crypto_object_attribute_t *,
 233  233      uint_t, uint64_t, ulong_t *);
↓ open down ↓ 1088 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX