Changeset a35b458 in mainline for kernel/generic/src/mm/backend_anon.c


Ignore:
Timestamp:
2018-03-02T20:10:49Z (7 years ago)
Author:
Jiří Zárevúcky <zarevucky.jiri@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
f1380b7
Parents:
3061bc1
git-author:
Jiří Zárevúcky <zarevucky.jiri@…> (2018-02-28 17:38:31)
git-committer:
Jiří Zárevúcky <zarevucky.jiri@…> (2018-03-02 20:10:49)
Message:

style: Remove trailing whitespace on _all_ lines, including empty ones, for particular file types.

Command used: tools/srepl '\s\+$' '' -- *.c *.h *.py *.sh *.s *.S *.ag

Currently, whitespace on empty lines is very inconsistent.
There are two basic choices: Either remove the whitespace, or keep empty lines
indented to the level of surrounding code. The former is AFAICT more common,
and also much easier to do automatically.

Alternatively, we could write script for automatic indentation, and use that
instead. However, if such a script exists, it's possible to use the indented
style locally, by having the editor apply relevant conversions on load/save,
without affecting remote repository. IMO, it makes more sense to adopt
the simpler rule.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/generic/src/mm/backend_anon.c

    r3061bc1 ra35b458  
    125125            node) {
    126126                unsigned int i;
    127                
     127
    128128                for (i = 0; i < node->keys; i++) {
    129129                        uintptr_t base = node->key[i];
    130130                        size_t count = (size_t) node->value[i];
    131131                        unsigned int j;
    132                        
     132
    133133                        for (j = 0; j < count; j++) {
    134134                                pte_t pte;
    135135                                bool found;
    136                        
     136
    137137                                page_table_lock(area->as, false);
    138138                                found = page_mapping_find(area->as,
     
    201201        if (area->sh_info->shared) {
    202202                btree_node_t *leaf;
    203                
     203
    204204                /*
    205205                 * The area is shared, chances are that the mapping can be found
     
    214214                        bool allocate = true;
    215215                        unsigned int i;
    216                        
     216
    217217                        /*
    218218                         * Zero can be returned as a valid frame address.
     
    230230                                memsetb((void *) kpage, PAGE_SIZE, 0);
    231231                                km_temporary_page_put(kpage);
    232                                
     232
    233233                                /*
    234234                                 * Insert the address of the newly allocated
     
    272272        }
    273273        mutex_unlock(&area->sh_info->lock);
    274        
     274
    275275        /*
    276276         * Map 'upage' to 'frame'.
     
    281281        if (!used_space_insert(area, upage, 1))
    282282                panic("Cannot insert used space.");
    283                
     283
    284284        return AS_PF_OK;
    285285}
Note: See TracChangeset for help on using the changeset viewer.