Print this page
8626 make pcplusmp and apix warning-free
Reviewed by: Robert Mustacchi <rm@joyent.com>
Reviewed by: Jerry Jelinek <jerry.jelinek@joyent.com>

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/i86pc/io/mp_platform_common.c
          +++ new/usr/src/uts/i86pc/io/mp_platform_common.c
↓ open down ↓ 14 lines elided ↑ open up ↑
  15   15   * If applicable, add the following below this CDDL HEADER, with the
  16   16   * fields enclosed by brackets "[]" replaced with your own identifying
  17   17   * information: Portions Copyright [yyyy] [name of copyright owner]
  18   18   *
  19   19   * CDDL HEADER END
  20   20   */
  21   21  /*
  22   22   * Copyright (c) 2007, 2010, Oracle and/or its affiliates. All rights reserved.
  23   23   * Copyright 2016 Nexenta Systems, Inc.
  24   24   * Copyright (c) 2017 by Delphix. All rights reserved.
       25 + * Copyright 2017 Joyent, Inc.
  25   26   */
  26   27  /*
  27   28   * Copyright (c) 2010, Intel Corporation.
  28   29   * All rights reserved.
  29   30   */
  30   31  
  31   32  /*
  32   33   * PSMI 1.1 extensions are supported only in 2.6 and later versions.
  33   34   * PSMI 1.2 extensions are supported only in 2.7 and later versions.
  34   35   * PSMI 1.3 and 1.4 extensions are supported in Solaris 10.
↓ open down ↓ 288 lines elided ↑ open up ↑
 323  324   * 3. In the BIOS ROM address space between 0F0000h and 0FFFFh
 324  325   * Once we find the right signature with proper checksum, we call
 325  326   * either handle_defconf or parse_mpct to get all info necessary for
 326  327   * subsequent operations.
 327  328   */
 328  329  int
 329  330  apic_probe_common(char *modname)
 330  331  {
 331  332          uint32_t mpct_addr, ebda_start = 0, base_mem_end;
 332  333          caddr_t biosdatap;
 333      -        caddr_t mpct = 0;
      334 +        caddr_t mpct = NULL;
 334  335          caddr_t fptr;
 335      -        int     i, mpct_size, mapsize, retval = PSM_FAILURE;
      336 +        int     i, mpct_size = 0, mapsize, retval = PSM_FAILURE;
 336  337          ushort_t        ebda_seg, base_mem_size;
 337  338          struct  apic_mpfps_hdr  *fpsp;
 338  339          struct  apic_mp_cnf_hdr *hdrp;
 339  340          int bypass_cpu_and_ioapics_in_mptables;
 340  341          int acpi_user_options;
 341  342  
 342  343          if (apic_forceload < 0)
 343  344                  return (retval);
 344  345  
 345  346          /*
↓ open down ↓ 2099 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX