Skip to content
Snippets Groups Projects
Commit 2005a594 authored by Moe Jette's avatar Moe Jette
Browse files

properly handle situation where a node is configured with

CPUS = SOCKETS * CORES
but THREADS != 1
in that case, reset select/cons_res internal node table to thread count = 1
parent 67d68b88
No related branches found
No related tags found
No related merge requests found
...@@ -1690,7 +1690,7 @@ extern int select_p_job_init(List job_list) ...@@ -1690,7 +1690,7 @@ extern int select_p_job_init(List job_list)
*/ */
extern int select_p_node_init(struct node_record *node_ptr, int node_cnt) extern int select_p_node_init(struct node_record *node_ptr, int node_cnt)
{ {
int i; int i, tot_core;
info("cons_res: select_p_node_init"); info("cons_res: select_p_node_init");
if (node_ptr == NULL) { if (node_ptr == NULL) {
...@@ -1733,6 +1733,10 @@ extern int select_p_node_init(struct node_record *node_ptr, int node_cnt) ...@@ -1733,6 +1733,10 @@ extern int select_p_node_init(struct node_record *node_ptr, int node_cnt)
select_node_record[i].real_memory = node_ptr[i]. select_node_record[i].real_memory = node_ptr[i].
real_memory; real_memory;
} }
tot_core = select_node_record[i].sockets *
select_node_record[i].cores;
if (tot_core >= select_node_record[i].cpus)
select_node_record[i].vpus = 1;
select_node_usage[i].node_state = NODE_CR_AVAILABLE; select_node_usage[i].node_state = NODE_CR_AVAILABLE;
gres_plugin_node_state_dealloc_all(select_node_record[i]. gres_plugin_node_state_dealloc_all(select_node_record[i].
node_ptr->gres_list); node_ptr->gres_list);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment