ia64/xen-unstable

changeset 15888:0902e4aae810

[IA64] Make local functions static, indentation

Signed-off-by: Tristan Gingold <tgingold@free.fr>
author Alex Williamson <alex.williamson@hp.com>
date Mon Sep 17 11:08:46 2007 -0600 (2007-09-17)
parents 0f16d41ebb0b
children b91d16ab68be
files xen/arch/ia64/vmx/vtlb.c
line diff
     1.1 --- a/xen/arch/ia64/vmx/vtlb.c	Mon Sep 17 11:04:29 2007 -0600
     1.2 +++ b/xen/arch/ia64/vmx/vtlb.c	Mon Sep 17 11:08:46 2007 -0600
     1.3 @@ -23,7 +23,7 @@
     1.4  
     1.5  #include <asm/vmx_vcpu.h>
     1.6  
     1.7 -thash_data_t *__alloc_chain(thash_cb_t *);
     1.8 +static thash_data_t *__alloc_chain(thash_cb_t *);
     1.9  
    1.10  static inline void cch_mem_init(thash_cb_t *hcb)
    1.11  {
    1.12 @@ -54,7 +54,7 @@ static thash_data_t *cch_alloc(thash_cb_
    1.13  
    1.14  static inline int __is_tr_translated(thash_data_t *trp, u64 rid, u64 va)
    1.15  {
    1.16 -    return ((trp->p) && (trp->rid == rid) && ((va-trp->vadr)<PSIZE(trp->ps)));
    1.17 +    return (trp->p) && (trp->rid == rid) && ((va-trp->vadr) < PSIZE(trp->ps));
    1.18  }
    1.19  
    1.20  /*
    1.21 @@ -78,14 +78,14 @@ static int
    1.22  
    1.23  }
    1.24  
    1.25 -thash_data_t *__vtr_lookup(VCPU *vcpu, u64 va, int is_data)
    1.26 +static thash_data_t *__vtr_lookup(VCPU *vcpu, u64 va, int is_data)
    1.27  {
    1.28  
    1.29      thash_data_t  *trp;
    1.30      int  i;
    1.31      u64 rid;
    1.32      vcpu_get_rr(vcpu, va, &rid);
    1.33 -    rid = rid&RR_RID_MASK;;
    1.34 +    rid = rid & RR_RID_MASK;;
    1.35      if (is_data) {
    1.36          if (vcpu_quick_region_check(vcpu->arch.dtr_regions,va)) {
    1.37              for (trp =(thash_data_t *) vcpu->arch.dtrs,i=0; i<NDTRS; i++, trp++) {
    1.38 @@ -380,12 +380,12 @@ void thash_recycle_cch_all(thash_cb_t *h
    1.39  }
    1.40  
    1.41  
    1.42 -thash_data_t *__alloc_chain(thash_cb_t *hcb)
    1.43 +static thash_data_t *__alloc_chain(thash_cb_t *hcb)
    1.44  {
    1.45      thash_data_t *cch;
    1.46  
    1.47      cch = cch_alloc(hcb);
    1.48 -    if(cch == NULL){
    1.49 +    if (cch == NULL) {
    1.50          thash_recycle_cch_all(hcb);
    1.51          cch = cch_alloc(hcb);
    1.52      }
    1.53 @@ -448,8 +448,9 @@ int vtr_find_overlap(VCPU *vcpu, u64 va,
    1.54      thash_data_t  *trp;
    1.55      int  i;
    1.56      u64 end, rid;
    1.57 +
    1.58      vcpu_get_rr(vcpu, va, &rid);
    1.59 -    rid = rid&RR_RID_MASK;;
    1.60 +    rid = rid & RR_RID_MASK;;
    1.61      end = va + PSIZE(ps);
    1.62      if (is_data) {
    1.63          if (vcpu_quick_region_check(vcpu->arch.dtr_regions,va)) {
    1.64 @@ -640,9 +641,10 @@ thash_data_t *vtlb_lookup(VCPU *v, u64 v
    1.65      thash_cb_t * hcb= &v->arch.vtlb;
    1.66  
    1.67      cch = __vtr_lookup(v, va, is_data);;
    1.68 -    if ( cch ) return cch;
    1.69 +    if (cch)
    1.70 +	return cch;
    1.71  
    1.72 -    if(vcpu_quick_region_check(v->arch.tc_regions,va)==0)
    1.73 +    if (vcpu_quick_region_check(v->arch.tc_regions,va) == 0)
    1.74          return NULL;
    1.75      psbits = VMX(v, psbits[(va >> 61)]);
    1.76      vcpu_get_rr(v,va,&vrr.rrval);