* GPL HEADER END
*/
/*
- * Copyright 2008 Sun Microsystems, Inc. All rights reserved.
+ * Copyright (c) 2008, 2010, Oracle and/or its affiliates. All rights reserved.
* Use is subject to license terms.
*/
/*
struct osc_page *opg = cl2osc_page(slice);
struct osc_object *obj = cl2osc(opg->ops_cl.cpl_obj);
int result;
- int brw_flags;
+ /* All cacheable IO is async-capable */
+ int brw_flags = OBD_BRW_ASYNC;
int noquota = 0;
LINVRNT(osc_page_protected(env, opg, CLM_WRITE, 0));
ENTRY;
/* Set the OBD_BRW_SRVLOCK before the page is queued. */
- brw_flags = opg->ops_srvlock ? OBD_BRW_SRVLOCK : 0;
+ brw_flags |= opg->ops_srvlock ? OBD_BRW_SRVLOCK : 0;
if (!client_is_remote(osc_export(obj)) &&
cfs_capable(CFS_CAP_SYS_RESOURCE)) {
brw_flags |= OBD_BRW_NOQUOTA;
return (*printer)(env, cookie, LUSTRE_OSC_NAME"-page@%p: "
"1< %#x %d %u %s %s %s > "
- "2< %llu %u %#x %#x | %p %p %p %p %p > "
+ "2< "LPU64" %u %#x %#x | %p %p %p %p %p > "
"3< %s %p %d %lu %d > "
"4< %d %d %d %lu %s | %s %s %s %s > "
"5< %s %s %s %s | %d %s %s | %d %s %s>\n",
oap->oap_page_off = opg->ops_from;
oap->oap_count = opg->ops_to - opg->ops_from;
/* Give a hint to OST that requests are coming from kswapd - bug19529 */
- if (libcfs_memory_pressure_get())
+ if (cfs_memory_pressure_get())
oap->oap_brw_flags |= OBD_BRW_MEMALLOC;
oap->oap_brw_flags |= OBD_BRW_SYNC;
if (osc_io_srvlock(oio))