btrfs: Attempt to fix GCC2 build.
[haiku.git] / src / system / kernel / vm / VMDeviceCache.cpp
blobd94bf72d5ca4ee4b8d4df03e2c55ed59f8325847
1 /*
2 * Copyright 2004-2007, Axel Dörfler, axeld@pinc-software.de.
3 * Distributed under the terms of the MIT License.
5 * Copyright 2001-2002, Travis Geiselbrecht. All rights reserved.
6 * Distributed under the terms of the NewOS License.
7 */
10 #include "VMDeviceCache.h"
12 #include <slab/Slab.h>
15 status_t
16 VMDeviceCache::Init(addr_t baseAddress, uint32 allocationFlags)
18 fBaseAddress = baseAddress;
19 return VMCache::Init(CACHE_TYPE_DEVICE, allocationFlags);
23 status_t
24 VMDeviceCache::Read(off_t offset, const generic_io_vec *vecs, size_t count,
25 uint32 flags, generic_size_t *_numBytes)
27 panic("device_store: read called. Invalid!\n");
28 return B_ERROR;
32 status_t
33 VMDeviceCache::Write(off_t offset, const generic_io_vec* vecs, size_t count,
34 uint32 flags, generic_size_t* _numBytes)
36 // no place to write, this will cause the page daemon to skip this store
37 return B_OK;
41 void
42 VMDeviceCache::DeleteObject()
44 object_cache_delete(gDeviceCacheObjectCache, this);