/* $Id: cache.h,v 1.6 2004/03/11 18:08:05 lethal Exp $1*2* include/asm-sh/cache.h3*4* Copyright 1999 (C) Niibe Yutaka5* Copyright 2002, 2003 (C) Paul Mundt6*/7#ifndef __ASM_SH_CACHE_H8#define __ASM_SH_CACHE_H9#ifdef __KERNEL__1011#include <linux/init.h>12#include <cpu/cache.h>1314#define L1_CACHE_BYTES (1 << L1_CACHE_SHIFT)1516#define __read_mostly __attribute__((__section__(".data..read_mostly")))1718#ifndef __ASSEMBLY__19struct cache_info {20unsigned int ways; /* Number of cache ways */21unsigned int sets; /* Number of cache sets */22unsigned int linesz; /* Cache line size (bytes) */2324unsigned int way_size; /* sets * line size */2526/*27* way_incr is the address offset for accessing the next way28* in memory mapped cache array ops.29*/30unsigned int way_incr;31unsigned int entry_shift;32unsigned int entry_mask;3334/*35* Compute a mask which selects the address bits which overlap between36* 1. those used to select the cache set during indexing37* 2. those in the physical page number.38*/39unsigned int alias_mask;40unsigned int n_aliases; /* Number of aliases */4142unsigned long flags;43};44#endif /* __ASSEMBLY__ */45#endif /* __KERNEL__ */46#endif /* __ASM_SH_CACHE_H */474849