Lines Matching defs:class

272 	if (!oh->class->sysc) {
273 WARN(1, "omap_hwmod: %s: cannot read OCP_SYSCONFIG: not defined on hwmod's class\n", oh->name);
279 oh->_sysc_cache = omap_hwmod_read(oh, oh->class->sysc->sysc_offs);
281 if (!(oh->class->sysc->sysc_flags & SYSC_NO_CACHE))
292 * Write @v into the module class' OCP_SYSCONFIG register, if it has
297 if (!oh->class->sysc) {
298 WARN(1, "omap_hwmod: %s: cannot write OCP_SYSCONFIG: not defined on hwmod's class\n", oh->name);
313 if (oh->class->unlock)
314 oh->class->unlock(oh);
316 omap_hwmod_write(v, oh, oh->class->sysc->sysc_offs);
318 if (oh->class->lock)
319 oh->class->lock(oh);
338 if (!oh->class->sysc ||
339 !(oh->class->sysc->sysc_flags & SYSC_HAS_MIDLEMODE))
342 if (!oh->class->sysc->sysc_fields) {
343 WARN(1, "omap_hwmod: %s: offset struct for sysconfig not provided in class\n", oh->name);
347 mstandby_shift = oh->class->sysc->sysc_fields->midle_shift;
371 if (!oh->class->sysc ||
372 !(oh->class->sysc->sysc_flags & SYSC_HAS_SIDLEMODE))
375 if (!oh->class->sysc->sysc_fields) {
376 WARN(1, "omap_hwmod: %s: offset struct for sysconfig not provided in class\n", oh->name);
380 sidle_shift = oh->class->sysc->sysc_fields->sidle_shift;
405 if (!oh->class->sysc ||
406 !(oh->class->sysc->sysc_flags & SYSC_HAS_CLOCKACTIVITY))
409 if (!oh->class->sysc->sysc_fields) {
410 WARN(1, "omap_hwmod: %s: offset struct for sysconfig not provided in class\n", oh->name);
414 clkact_shift = oh->class->sysc->sysc_fields->clkact_shift;
435 if (!oh->class->sysc ||
436 !(oh->class->sysc->sysc_flags & SYSC_HAS_SOFTRESET))
439 if (!oh->class->sysc->sysc_fields) {
440 WARN(1, "omap_hwmod: %s: offset struct for sysconfig not provided in class\n", oh->name);
444 softrst_mask = (0x1 << oh->class->sysc->sysc_fields->srst_shift);
463 if (!oh->class->sysc ||
464 !(oh->class->sysc->sysc_flags & SYSC_HAS_SOFTRESET))
467 if (!oh->class->sysc->sysc_fields) {
469 "omap_hwmod: %s: sysc_fields absent for sysconfig class\n",
474 softrst_mask = (0x1 << oh->class->sysc->sysc_fields->srst_shift);
497 sysc = oh->class->sysc;
530 if (!oh->class->sysc ||
531 !(oh->class->sysc->sysc_flags & SYSC_HAS_DMADISABLE))
534 if (!oh->class->sysc->sysc_fields) {
535 WARN(1, "omap_hwmod: %s: offset struct for sysconfig not provided in class\n", oh->name);
549 (0x1 << oh->class->sysc->sysc_fields->dmadisable_shift);
575 if (!oh->class->sysc ||
576 !(oh->class->sysc->sysc_flags & SYSC_HAS_AUTOIDLE))
579 if (!oh->class->sysc->sysc_fields) {
580 WARN(1, "omap_hwmod: %s: offset struct for sysconfig not provided in class\n", oh->name);
584 autoidle_shift = oh->class->sysc->sysc_fields->autoidle_shift;
602 if (!oh->class->sysc ||
603 !((oh->class->sysc->sysc_flags & SYSC_HAS_ENAWAKEUP) ||
604 (oh->class->sysc->idlemodes & SIDLE_SMART_WKUP) ||
605 (oh->class->sysc->idlemodes & MSTANDBY_SMART_WKUP)))
608 if (!oh->class->sysc->sysc_fields) {
609 WARN(1, "omap_hwmod: %s: offset struct for sysconfig not provided in class\n", oh->name);
613 if (oh->class->sysc->sysc_flags & SYSC_HAS_ENAWAKEUP)
614 *v |= 0x1 << oh->class->sysc->sysc_fields->enwkup_shift;
616 if (oh->class->sysc->idlemodes & SIDLE_SMART_WKUP)
618 if (oh->class->sysc->idlemodes & MSTANDBY_SMART_WKUP)
1178 if (!oh->class->sysc)
1194 sf = oh->class->sysc->sysc_flags;
1204 if (oh->class->sysc->idlemodes & SIDLE_SMART_WKUP)
1215 if (clkdm_act && !(oh->class->sysc->idlemodes &
1230 if (oh->class->sysc->idlemodes & MSTANDBY_SMART_WKUP)
1275 if (!oh->class->sysc)
1279 sf = oh->class->sysc->sysc_flags;
1287 if (oh->class->sysc->idlemodes & SIDLE_SMART_WKUP)
1302 if (oh->class->sysc->idlemodes & MSTANDBY_SMART_WKUP)
1327 if (!oh->class->sysc)
1331 sf = oh->class->sysc->sysc_flags;
1698 if (!oh->class->sysc ||
1699 !(oh->class->sysc->sysc_flags & SYSC_HAS_SOFTRESET))
1722 if (oh->class->sysc->srst_udelay)
1723 udelay(oh->class->sysc->srst_udelay);
1792 if (oh->class->reset) {
1793 r = oh->class->reset(oh);
1813 if (oh->class->sysc) {
1935 if (oh->class->sysc) {
1980 if (oh->class->sysc)
2040 if (oh->class->pre_shutdown) {
2044 ret = oh->class->pre_shutdown(oh);
2052 if (oh->class->sysc) {
2285 if (!oh->class->sysc)
2583 * omap_hwmod's class field is NULL; if the omap_hwmod is missing a
2584 * name, or if the omap_hwmod's class is missing a name; or 0 upon
2595 if (!oh || !oh->name || !oh->class || !oh->class->name ||
3196 if (!oh->class->sysc->sysc_fields)
3363 if (!oh->class->sysc)
3366 if (oh->class->sysc->sysc_fields &&
3367 sysc_fields != oh->class->sysc->sysc_fields)
3370 if (rev_offs != oh->class->sysc->rev_offs)
3372 oh->class->sysc->rev_offs);
3373 if (sysc_offs != oh->class->sysc->sysc_offs)
3375 oh->class->sysc->sysc_offs);
3376 if (syss_offs != oh->class->sysc->syss_offs)
3378 oh->class->sysc->syss_offs);
3380 if (sysc_flags != oh->class->sysc->sysc_flags)
3382 oh->class->sysc->sysc_flags);
3384 if (idlemodes != oh->class->sysc->idlemodes)
3386 oh->class->sysc->idlemodes);
3388 if (data->cfg->srst_udelay != oh->class->sysc->srst_udelay)
3391 oh->class->sysc->srst_udelay);
3419 struct omap_hwmod_class *class = NULL;
3444 * We may need a new oh->class as the other devices in the same class
3447 if (oh->class->name && strcmp(oh->class->name, data->name)) {
3448 class = kmemdup(oh->class, sizeof(*oh->class), GFP_KERNEL);
3449 if (!class)
3470 if (class)
3471 oh->class = class;
3472 oh->class->sysc = sysc;
3485 kfree(class);
3520 oh->class->reset = quirk->reset;
3576 oh->class = kzalloc(sizeof(*oh->class), GFP_KERNEL);
3577 if (!oh->class) {
3584 oh->class->name = data->name;
3899 * omap_hwmod_for_each_by_class - call @fn for each hwmod of class @classname
3901 * @fn: callback function pointer to call for each hwmod in class @classname
3904 * For each omap_hwmod of class @classname, call @fn.
3921 pr_debug("omap_hwmod: %s: looking for modules of class %s\n",
3925 if (!strcmp(temp_oh->class->name, classname)) {