Benign repos Download

adi-i3c-master.c

Includes Linux kernel module headerAssigns a negative errno constant
SHA-256a75d87df42499d0171fe5dfbcdc7c36cf76f1111668f0f28c38e1a36f199bec3
MaleculeO(Er)H(Os)

Evidence

Includes Linux kernel module header lines 1–26
⋯5 lines
6 */
7
8#include <linux/bitops.h>
9#include <linux/bitfield.h>
10#include <linux/clk.h>
11#include <linux/err.h>
12#include <linux/errno.h>
13#include <linux/adi-axi-common.h>
14#include <linux/i3c/master.h>
15#include <linux/interrupt.h>
16#include <linux/io.h>
17#include <linux/module.h>
18#include <linux/of.h>
19#include <linux/platform_device.h>
20
21#include "../internals.h"
22
23#define ADI_MAX_DEVS 16
24#define ADI_HAS_MDB_FROM_BCR(x) (FIELD_GET(BIT(2), (x)))
25
26#define …
English function-word token "for" lines 204–212
204 unsigned int i, n, m;
205
206 if (!xfer)
207 return;
208
209 for (i = 0; i < xfer->ncmds; i++) {
210 struct adi_i3c_cmd *cmd = &xfer->cmds[i];
211
212 if (!(cmd->cmd0 …
Assigns a negative errno constant lines 260–278
260 case REG_CMDR_FIFO_NACK_RESP:
261 case REG_CMDR_FIFO_UDA_ERROR:
262 ret = -EIO;
263 break;
264
265 default:
266 ret = -EINVAL;
267 break;
268 }
⋯10 lines
Kernel error code return lines 337–344
337:32… ee(kfree) = adi_i3c_master_alloc_xfer(master, 1);
338 if (!xfer)
339 return -ENOMEM;
340
341 ccmd = xfer->cmds;
342 ccmd->cmd1 = REG_CMD_FIFO_1_CCC(cmd->id);
343 ccmd->cmd0 = REG_CMD_FIFO_0_IS_CCC |
344 REG_CMD_FIFO_0_LE …
English function-word token "and" lines 622–629
622:21… ce_info *info)
623{
624 u32 buf;
625
626 /* Dynamic address and PID are for identification only */
627 memset(info, 0, sizeof(*info));
628 buf = readl(master->regs + REG_DCR_BCR_DA);
629 info->dyn_addr = REG_DCR …

Keyboard shortcuts on this page: j for the next sample, k for the previous one, x to go back to the feed, d to download the original bytes, r to re-queue the sample for analysis.