Anforderungen  |   Konzepte  |   Entwurf  |   Entwicklung  |   Qualitätssicherung  |   Lebenszyklus  |   Steuerung
 
 
 
 


Quelle  pm_helpers.h   Sprache: C

 
/* SPDX-License-Identifier: GPL-2.0-only */
/* Copyright (C) 2019 Linaro Ltd. */
#ifndef __VENUS_PM_HELPERS_H__
#define __VENUS_PM_HELPERS_H__

struct device;
struct venus_core;

#define POWER_ON 1
#define POWER_OFF 0

struct venus_pm_ops {
 int (*core_get)(struct venus_core *core);
 void (*core_put)(struct venus_core *core);
 int (*core_power)(struct venus_core *core, int on);

 int (*vdec_get)(struct device *dev);
 void (*vdec_put)(struct device *dev);
 int (*vdec_power)(struct device *dev, int on);

 int (*venc_get)(struct device *dev);
 void (*venc_put)(struct device *dev);
 int (*venc_power)(struct device *dev, int on);

 int (*coreid_power)(struct venus_inst *inst, int on);

 int (*load_scale)(struct venus_inst *inst);
};

const struct venus_pm_ops *venus_pm_get(enum hfi_version version);

static inline int venus_pm_load_scale(struct venus_inst *inst)
{
 struct venus_core *core = inst->core;

 if (!core->pm_ops || !core->pm_ops->load_scale)
  return 0;

 return core->pm_ops->load_scale(inst);
}

static inline int venus_pm_acquire_core(struct venus_inst *inst)
{
 struct venus_core *core = inst->core;
 const struct venus_pm_ops *pm_ops = core->pm_ops;
 int ret = 0;

 if (pm_ops && pm_ops->coreid_power)
  ret = pm_ops->coreid_power(inst, POWER_ON);

 return ret;
}

static inline int venus_pm_release_core(struct venus_inst *inst)
{
 struct venus_core *core = inst->core;
 const struct venus_pm_ops *pm_ops = core->pm_ops;
 int ret = 0;

 if (pm_ops && pm_ops->coreid_power)
  ret = pm_ops->coreid_power(inst, POWER_OFF);

 return ret;
}

#endif

Messung V0.5
C=99 H=95 G=96

¤ Dauer der Verarbeitung: 0.1 Sekunden  (vorverarbeitet)  ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

Beweissystem der NASA

Beweissystem Isabelle

NIST Cobol Testsuite

Cephes Mathematical Library

Wiener Entwicklungsmethode

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.






                                                                                                                                                                                                                                                                                                                                                                                                     


Neuigkeiten

     Aktuelles
     Motto des Tages

Software

     Produkte
     Quellcodebibliothek

Aktivitäten

     Artikel über Sicherheit
     Anleitung zur Aktivierung von SSL

Muße

     Gedichte
     Musik
     Bilder

Jenseits des Üblichen ....
    

Besucherstatistik

Besucherstatistik

Monitoring

Montastic status badge