Lines Matching full:board
23 BOARD_SCHEMA_PATH = str(Path(__file__).parent / 'schemas' / 'board-schema.yml')
27 BOARD_YML = 'board.yml'
92 class Board: class
94 # HWMv1 only supports a single Path, and requires Board dataclass to be hashable.
109 # Get the main board directory.
145 sys.exit(f'ERROR: qualifiers {qualifiers} not found when extending board {self.name}')
150 def board_key(board): argument
151 return board.name
171 if args.board is not None:
172 ret[arch] |= {b for b in boards if b.name == args.board}
220 ret[arch].add(Board(board_name, maybe_board, 'v1', arch=arch))
238 mutual_exclusive = {'board', 'boards'}
243 board_array = b.get('boards', [b.get('board', None)])
244 for board in board_array:
246 if len(mutual_exclusive - board.keys()) < 1:
247 sys.exit(f'ERROR: Malformed "board" section in file: {board_yml.as_posix()}\n'
250 # This is a extending an existing board, place in array to allow later processing.
251 if 'extend' in board:
252 board.update({'dir': board_yml.parent})
253 board_extensions.append(board)
256 # Create board
258 if board['name'] != board_name:
259 # Not the board we're looking for, ignore.
262 board_revision = board.get('revision')
265 sys.exit(f'ERROR: Malformed "board" section in file: {board_yml.as_posix()}\n'
266 "Cannot find required key 'default'. Path: '/board/revision.'")
268 sys.exit(f'ERROR: Malformed "board" section in file: {board_yml.as_posix()}\n'
269 "Cannot find required key 'revisions'. Path: '/board/revision.'")
272 if len(mutual_exclusive - board.keys()) < 1:
273 sys.exit(f'ERROR: Malformed "board" section in file: {board_yml.as_posix()}\n'
276 for s in board.get('socs', {})]
278 boards[board['name']] = Board(
279 name=board['name'],
281 vendor=board.get('vendor'),
282 full_name=board.get('full_name'),
283 revision_format=board.get('revision', {}).get('format'),
284 revision_default=board.get('revision', {}).get('default'),
285 revision_exact=board.get('revision', {}).get('exact', False),
287 board.get('revision', {}).get('revisions', [])],
289 variants=[Variant.from_dict(v) for v in board.get('variants', [])],
292 board_qualifiers = board_v2_qualifiers(boards[board['name']])
295 sys.exit(f'ERROR: Duplicated board qualifiers detected {duplicates} for board: '
296 f'{board["name"]}.\nPlease check content of: {board_yml.as_posix()}\n')
302 board = boards.get(e['extend'])
303 if board is None:
305 board.directories.append(e['dir'])
308 node = board.from_qualifier(v['qualifier'])
309 if str(v['qualifier'] + '/' + v['name']) in board_v2_qualifiers(board):
311 sys.exit(f'ERROR: Variant: {v["name"]}, defined multiple times for board: '
312 f'{board.name}.\nLast defined in {board_yml}')
316 # Note that this does not share the args.board functionality of find_v2_boards
341 b, e = load_v2_boards(args.board, board_yml, systems)
344 sys.exit(f'ERROR: Board(s): {conflict_boards}, defined multiple times.\n'
366 parser.add_argument("--board-root", dest='board_roots', default=[],
368 help='add a board root, may be given more than once')
372 parser.add_argument("--board", dest='board', default=None,
373 help='lookup the specific board, fail if not found')
374 parser.add_argument("--board-dir", default=[], type=Path, action='append',
380 help='''CMake Format string to use to list each board''')
390 def board_v2_qualifiers(board): argument
393 for s in board.socs:
405 for v in board.variants:
410 def board_v2_qualifiers_csv(board): argument
412 return ",".join(board_v2_qualifiers(board))
446 for board in boards:
449 NAME='NAME;' + board.name,
450 DIR='DIR;' + str(board.dir.as_posix()),
451 HWM='HWM;' + board.hwm,
463 print(f' {board.name}')