29949e866e40b95795203f3ee46f44a197c946e4stevel * CDDL HEADER START
29949e866e40b95795203f3ee46f44a197c946e4stevel * The contents of this file are subject to the terms of the
29949e866e40b95795203f3ee46f44a197c946e4stevel * Common Development and Distribution License (the "License").
29949e866e40b95795203f3ee46f44a197c946e4stevel * You may not use this file except in compliance with the License.
29949e866e40b95795203f3ee46f44a197c946e4stevel * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
29949e866e40b95795203f3ee46f44a197c946e4stevel * See the License for the specific language governing permissions
29949e866e40b95795203f3ee46f44a197c946e4stevel * and limitations under the License.
29949e866e40b95795203f3ee46f44a197c946e4stevel * When distributing Covered Code, include this CDDL HEADER in each
29949e866e40b95795203f3ee46f44a197c946e4stevel * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
29949e866e40b95795203f3ee46f44a197c946e4stevel * If applicable, add the following below this CDDL HEADER, with the
29949e866e40b95795203f3ee46f44a197c946e4stevel * fields enclosed by brackets "[]" replaced with your own identifying
29949e866e40b95795203f3ee46f44a197c946e4stevel * information: Portions Copyright [yyyy] [name of copyright owner]
29949e866e40b95795203f3ee46f44a197c946e4stevel * CDDL HEADER END
29949e866e40b95795203f3ee46f44a197c946e4stevel * Copyright 1998 Sun Microsystems, Inc. All rights reserved.
29949e866e40b95795203f3ee46f44a197c946e4stevel * Use is subject to license terms.
29949e866e40b95795203f3ee46f44a197c946e4stevel#pragma ident "%Z%%M% %I% %E% SMI"
29949e866e40b95795203f3ee46f44a197c946e4stevelstatic void query_checker(pfn_t, pgcnt_t, memquery_t *);
29949e866e40b95795203f3ee46f44a197c946e4stevel#endif /* DEBUG */
29949e866e40b95795203f3ee46f44a197c946e4stevel * Is the specified bank present?
29949e866e40b95795203f3ee46f44a197c946e4stevel /* verify the board is of the correct type */
29949e866e40b95795203f3ee46f44a197c946e4stevel * Busy could also be set for fhc_bd_busy(ac->board)
29949e866e40b95795203f3ee46f44a197c946e4stevel * however, this is just advisory information so limit it
29949e866e40b95795203f3ee46f44a197c946e4stevel * to memory operation in progress.
29949e866e40b95795203f3ee46f44a197c946e4stevel * Determine the physical location of the selected bank
29949e866e40b95795203f3ee46f44a197c946e4stevel if (mem_info->ostate == SYSC_CFGA_OSTATE_CONFIGURED) {
29949e866e40b95795203f3ee46f44a197c946e4stevel * This can happen in normal concurrent
29949e866e40b95795203f3ee46f44a197c946e4stevel * operation.
29949e866e40b95795203f3ee46f44a197c946e4stevel "memq.phys_pages != npgs (%ld != %ld)",
29949e866e40b95795203f3ee46f44a197c946e4stevel#endif /* DEBUG */
29949e866e40b95795203f3ee46f44a197c946e4stevel if (mem_info->rstate == SYSC_CFGA_RSTATE_CONNECTED) {
29949e866e40b95795203f3ee46f44a197c946e4stevel /* Bank is in state Spare */
29949e866e40b95795203f3ee46f44a197c946e4stevel /* return the information to the user */
29949e866e40b95795203f3ee46f44a197c946e4stevel stat32p = kmem_zalloc(sizeof (ac_stat32_t), KM_SLEEP);
29949e866e40b95795203f3ee46f44a197c946e4stevel#else /* _MULTI_DATAMODEL */
29949e866e40b95795203f3ee46f44a197c946e4stevel#endif /* _MULTI_DATAMODEL */
29949e866e40b95795203f3ee46f44a197c946e4stevel if (amemq.phys_pages != 0 && amemq.phys_pages != 1) {
29949e866e40b95795203f3ee46f44a197c946e4stevel if (amemq.nonrelocatable != 0 && amemq.nonrelocatable != 1) {
29949e866e40b95795203f3ee46f44a197c946e4stevel printf("%ld: nonrelocatable = %ld, expected 0 or 1\n",
29949e866e40b95795203f3ee46f44a197c946e4stevel if (mqp->first_nonrelocatable != memq.first_nonrelocatable) {
29949e866e40b95795203f3ee46f44a197c946e4stevel mqp->first_nonrelocatable, memq.first_nonrelocatable);
29949e866e40b95795203f3ee46f44a197c946e4stevel if (mqp->last_nonrelocatable != memq.last_nonrelocatable) {
29949e866e40b95795203f3ee46f44a197c946e4stevel#endif /* DEBUG */