1f931551bSRalph Campbell /*
2f931551bSRalph Campbell * Copyright (c) 2006, 2007, 2008 QLogic Corporation. All rights reserved.
3f931551bSRalph Campbell *
4f931551bSRalph Campbell * This software is available to you under a choice of one of two
5f931551bSRalph Campbell * licenses. You may choose to be licensed under the terms of the GNU
6f931551bSRalph Campbell * General Public License (GPL) Version 2, available from the file
7f931551bSRalph Campbell * COPYING in the main directory of this source tree, or the
8f931551bSRalph Campbell * OpenIB.org BSD license below:
9f931551bSRalph Campbell *
10f931551bSRalph Campbell * Redistribution and use in source and binary forms, with or
11f931551bSRalph Campbell * without modification, are permitted provided that the following
12f931551bSRalph Campbell * conditions are met:
13f931551bSRalph Campbell *
14f931551bSRalph Campbell * - Redistributions of source code must retain the above
15f931551bSRalph Campbell * copyright notice, this list of conditions and the following
16f931551bSRalph Campbell * disclaimer.
17f931551bSRalph Campbell *
18f931551bSRalph Campbell * - Redistributions in binary form must reproduce the above
19f931551bSRalph Campbell * copyright notice, this list of conditions and the following
20f931551bSRalph Campbell * disclaimer in the documentation and/or other materials
21f931551bSRalph Campbell * provided with the distribution.
22f931551bSRalph Campbell *
23f931551bSRalph Campbell * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
24f931551bSRalph Campbell * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
25f931551bSRalph Campbell * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
26f931551bSRalph Campbell * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
27f931551bSRalph Campbell * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
28f931551bSRalph Campbell * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
29f931551bSRalph Campbell * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
30f931551bSRalph Campbell * SOFTWARE.
31f931551bSRalph Campbell */
32f931551bSRalph Campbell
33f931551bSRalph Campbell /*
34f931551bSRalph Campbell * This file is conditionally built on PowerPC only. Otherwise weak symbol
35f931551bSRalph Campbell * versions of the functions exported from here are used.
36f931551bSRalph Campbell */
37f931551bSRalph Campbell
38f931551bSRalph Campbell #include "qib.h"
39f931551bSRalph Campbell
40f931551bSRalph Campbell /**
41f931551bSRalph Campbell * qib_enable_wc - enable write combining for MMIO writes to the device
42f931551bSRalph Campbell * @dd: qlogic_ib device
43f931551bSRalph Campbell *
44f931551bSRalph Campbell * Nothing to do on PowerPC, so just return without error.
45f931551bSRalph Campbell */
qib_enable_wc(struct qib_devdata * dd)46f931551bSRalph Campbell int qib_enable_wc(struct qib_devdata *dd)
47f931551bSRalph Campbell {
48f931551bSRalph Campbell return 0;
49f931551bSRalph Campbell }
50f931551bSRalph Campbell
51f931551bSRalph Campbell /**
52f931551bSRalph Campbell * qib_unordered_wc - indicate whether write combining is unordered
53f931551bSRalph Campbell *
54f931551bSRalph Campbell * Because our performance depends on our ability to do write
55f931551bSRalph Campbell * combining mmio writes in the most efficient way, we need to
56f931551bSRalph Campbell * know if we are on a processor that may reorder stores when
57f931551bSRalph Campbell * write combining.
58f931551bSRalph Campbell */
qib_unordered_wc(void)59f931551bSRalph Campbell int qib_unordered_wc(void)
60f931551bSRalph Campbell {
61f931551bSRalph Campbell return 1;
62f931551bSRalph Campbell }
63