Lines Matching full:my
8 my $ccsregs = "ccs-regs.asc";
9 my $header;
10 my $regarray;
11 my $limitc;
12 my $limith;
13 my $kernel;
14 my $help;
43 my $lh_hdr = ! defined $kernel
46 my $uint32_t = ! defined $kernel ? 'uint32_t' : 'u32';
47 my $uint16_t = ! defined $kernel ? 'uint16_t' : 'u16';
49 open(my $R, "< $ccsregs") or die "can't open $ccsregs";
51 open(my $H, "> $header") or die "can't open $header";
52 my $A;
56 open(my $LC, "> $limitc") or die "can't open $limitc";
57 open(my $LH, "> $limith") or die "can't open $limith";
59 my %this;
62 my $addr = hex $_[0];
70 my $uc_header = basename uc $header;
73 my $copyright = "/* Copyright (C) 2019--2020 Intel Corporation */\n";
74 my $license = "SPDX-License-Identifier: GPL-2.0-only OR BSD-3-Clause";
75 my $note = "/*\n * Generated by $0;\n * do not modify.\n */\n";
77 for my $fh ($A, $LC) {
81 for my $fh ($H, $LH) {
103 my $flag = -1;
104 my $all_flags;
107 my $bit = shift @_;
117 my ($flag, $check) = @_;
121 my $flag_str = !$$flag ? "CCS_FL_BASE" : "(CCS_FL_BASE + $$flag)";
159 my $uc_limith = basename uc $limith;
192 my $limitcount = 0;
193 my $argdescs;
194 my $reglist = "const struct ccs_reg_desc ccs_reg_desc[] = {\n";
197 my ($name, $addr) = @_;
198 my $args;
203 foreach my $t (@$args) {
214 my @l = split "\n", $_;
225 my @flags = @_;
233 my $this = $_[0];
234 my $size = $this->{elsize};
235 my $h = $this->{argparams};
237 foreach my $arg (@{$this->{args}}) {
238 my $apref = $h->{$arg};
247 my ($this, $postfix, $is_same_reg) = @_;
248 my ($args, $argparams, $name) =
250 my $varname = "ccs_reg_arg_" . (lc $name) . $postfix;
251 my @mins;
252 my @sorted_args = @{$this->{sorted_args}};
253 my $lim_arg;
254 my $size = arr_size($this);
258 foreach my $sorted_arg (@sorted_args) {
262 foreach my $sorted_arg (@sorted_args) {
263 my $h = $argparams->{$sorted_arg};
282 my $hdr_data;
290 my ($bit, $addr) = split /\t+/;
295 my @a = split /\s+/;
296 my ($msb, $lsb, $this_field) = reverse @a;
300 foreach my $ar (@a) {
306 my ($enum, $addr) = split /\s+/;
310 my ($arg, $min, $max, $elsize, @discontig) = split /\s+/;
311 my $size;
313 foreach my $num ($min, $max) {
320 my $h = $this{argparams};
331 my $reg_formula = "$this{addr}";
332 my $lim_formula;
338 foreach my $arg (@{$this{args}}) {
339 my $d = $h->{$arg}->{discontig};
340 my $times = $h->{$arg}->{elsize} != 1 ?
344 my ($lim, $offset) = split /,/, $d->[0];
371 my $da = $this{argparams}->{$this{discontig}};
372 my ($first_discontig) = split /,/, $da->{discontig}->[0];
373 my $max = $da->{max};
400 my ($name, $addr, @flags) = split /\t+/, $_;
401 my $args = [];
403 my $sp;
409 my $flagstring = "";
410 my $bits = elem_bits(@flags);
420 my $base_addr = $addr;
428 my $arglist = @$args ? "(" . (join ", ", @$args) . ")" : "";