| 656 | } |
| 657 | |
| 658 | static int fill_layout_buffer(struct buffer *buff) |
| 659 | { |
| 660 | struct buffer wbuff; |
| 661 | |
| 662 | if (allocate_buffer(buff, &wbuff, "CSE layout")) |
| 663 | return -1; |
| 664 | |
| 665 | ifwi.cse_layout = ifwi.bpdt_ops->create_layout(¶ms.layout_regions[0]); |
| 666 | if (!ifwi.cse_layout) { |
| 667 | ERROR("Failed to create layout!\n"); |
| 668 | return -1; |
| 669 | } |
| 670 | |
| 671 | if (ifwi.bpdt_ops->write_layout(&wbuff, ifwi.cse_layout)) { |
| 672 | ERROR("Failed to write CSE layout!\n"); |
| 673 | return -1; |
| 674 | } |
| 675 | |
| 676 | return 0; |
| 677 | } |
| 678 | |
| 679 | static int cmd_create_layout(void) |
| 680 | { |
no test coverage detected