~ubuntu-branches/ubuntu/precise/slurm-llnl/precise

« back to all changes in this revision

Viewing changes to src/plugins/select/bluegene/plugin/bg_record_functions.h

  • Committer: Bazaar Package Importer
  • Author(s): Gennaro Oliva
  • Date: 2011-04-08 11:21:17 UTC
  • mfrom: (3.3.16 sid)
  • Revision ID: james.westby@ubuntu.com-20110408112117-nfnyq9dtm55hqoaw
Tags: 2.2.4-1
* New upstream releases 
* Cleaning spare file and directories, not belonging to the sources
  generated by the building process and not removed by distclean.
  Added debian/clean with spare files and rm -rf inside debian/rules
  for directories.
* Added new packages libslurm-perl, libslurmdb-perl, slurm-llnl-torque
  (Closes: #575822) thanks to Julien Blache

Show diffs side-by-side

added added

removed removed

Lines of Context:
58
58
 
59
59
#include "../block_allocator/block_allocator.h"
60
60
 
 
61
#define BLOCK_MAGIC 0x3afd
 
62
 
61
63
typedef struct bg_record {
62
64
        rm_partition_t *bg_block;       /* structure to hold info from db2 */
63
65
        pm_partition_id_t bg_block_id;  /* ID returned from MMCS        */
73
75
                                           0 = not booting,
74
76
                                           1 = booting */
75
77
        int bp_count;                   /* size */
76
 
        rm_connection_type_t conn_type;  /* MESH or Torus or NAV */
 
78
        rm_connection_type_t conn_type; /* MESH or Torus or NAV */
77
79
        uint32_t cpu_cnt;               /* count of cpus per block */
78
 
        int full_block;                 /* whether or not block is the full
 
80
        int free_cnt;                   /* How many are trying
 
81
                                           to free this block at the
 
82
                                           same time */
 
83
        bool full_block;                /* whether or not block is the full
79
84
                                           block */
80
 
        uint16_t geo[BA_SYSTEM_DIMENSIONS];  /* geometry */
 
85
        uint16_t geo[HIGHEST_DIMENSIONS];  /* geometry */
81
86
        char *ionodes;                  /* String of ionodes in block
82
87
                                         * NULL if not a small block*/
 
88
        bitstr_t *ionode_bitmap;        /* for small blocks bitmap to
 
89
                                           keep track which ionodes we
 
90
                                           are on.  NULL if not a small block*/
83
91
        struct job_record *job_ptr;     /* pointer to job running on
84
92
                                         * block or NULL if no job */
85
93
        int job_running;                /* job id of job running of if
86
94
                                         * block is in an error state
87
95
                                         * BLOCK_ERROR_STATE */
88
 
        bitstr_t *ionode_bitmap;        /* for small blocks bitmap to
89
 
                                           keep track which ionodes we
90
 
                                           are on.  NULL if not a small block*/
91
96
        char *linuximage;               /* LinuxImage/CnloadImage for
92
97
                                         * this block */
 
98
        uint16_t magic;                 /* magic number */
93
99
        char *mloaderimage;             /* mloaderImage for this block */
94
100
        int modifying;                  /* flag to say the block is
95
101
                                           being modified or not at
103
109
                                           pointer to the original */
104
110
        char *ramdiskimage;             /* RamDiskImage/IoloadImg for
105
111
                                         * this block */
 
112
        char *reason;                   /* reason block is in error state */
106
113
        rm_partition_state_t state;     /* Current state of the block */
107
 
        int start[BA_SYSTEM_DIMENSIONS];/* start node */
108
 
        int switch_count;               /* number of switches used. */
 
114
        uint16_t start[HIGHEST_DIMENSIONS];  /* start node */
 
115
        uint32_t switch_count;          /* number of switches used. */
109
116
        char *target_name;              /* when a block is freed this
110
117
                                           is the name of the user we
111
118
                                           want on the block */
131
138
   updated before call of function.
132
139
*/
133
140
extern int update_block_user(bg_record_t *bg_block_id, int set);
134
 
extern void drain_as_needed(bg_record_t *bg_record, char *reason);
135
 
 
136
 
extern int set_ionodes(bg_record_t *bg_record, int io_start, int io_nodes);
 
141
extern void requeue_and_error(bg_record_t *bg_record, char *reason);
137
142
 
138
143
extern int add_bg_record(List records, List used_nodes, blockreq_t *blockreq,
139
144
                         bool no_check, bitoff_t io_start);