-----channel.diff----- 1292c1292 < int err; --- > int err,cnt; 1361,1372c1361,1375 < if ((type == FEEDER_RATE && < !fmtvalid(fc->desc->in, fmtlist)) < || c->feeder->desc->out != fc->desc->in) { < DEB(printf("build fmtchain from 0x%x to 0x%x: ", c->feeder->desc->out, fc->desc->in)); < tmp[0] = fc->desc->in; < tmp[1] = 0; < if (chn_fmtchain(c, tmp) == 0) { < DEB(printf("failed\n")); < < return ENODEV; < } < DEB(printf("ok\n")); --- > DEB(printf("chn_buildfeeder>>c->format:%08x\n", c->format)); > DEB(printf("chn_buildfeeder>>fc->desc->in:%08x\n", fc->desc->in)); > DEB(printf("chn_buildfeeder>>fc->desc->out:%08x\n", fc->desc->out)); > DEB(printf("chn_buildfeeder>>c->feeder->desc->out:%08x\n", c->feeder->desc->out)); > cnt=-1; > while(fmtlist[++cnt]) > DEB(printf("chn_buildfeeder>>fmtlist[%i]:%08x\n", cnt, fmtlist[cnt])); > > DEB(printf("build fmtchain to 0x%x:\n", fc->desc->in)); > tmp[0] = fc->desc->in; > tmp[1] = 0; > if (chn_fmtchain(c, tmp) == 0) { > DEB(printf("failed\n")); > > return ENODEV; 1373a1377 > DEB(printf("ok\n")); 1385,1396c1389,1394 < if (fmtvalid(c->feeder->desc->out, fmtlist) < && !(c->direction == PCMDIR_REC && < c->format != c->feeder->desc->out)) < hwfmt = c->feeder->desc->out; < else { < if (c->direction == PCMDIR_REC) { < tmp[0] = c->format; < tmp[1] = 0; < hwfmt = chn_fmtchain(c, tmp); < } else < hwfmt = chn_fmtchain(c, fmtlist); < } --- > if (c->direction == PCMDIR_REC) { > tmp[0] = c->format; > tmp[1] = 0; > hwfmt = chn_fmtchain(c, tmp); > } else > hwfmt = chn_fmtchain(c, fmtlist); -----feeder.diff----- 268c268,271 < /* printf("trying %s (%x -> %x)...\n", source->class->name, source->desc->in, source->desc->out); */ --- > if (maxdepth < 0) > return NULL; > > DEB(printf("trying %s (%x -> %x)...\n", source->class->name, source->desc->in, source->desc->out)); 270c273 < /* printf("got it\n"); */ --- > DEB(printf("got it\n")); 274,276d276 < if (maxdepth < 0) < return NULL; < 323,326c323 < while (from[i] != 0) < i++; < while (i > 0) { < i--; --- > while (from[i] != 0) { 330a328 > DEB(printf("call feeder_fmtchain with maxdepth=%i\n",max)); 343a342 > i++; 348a348 > DEB(printf("call feeder_fmtchain for best chain (maxdepth=%i)\n",bestmax)); 376,385c376 < if (c->direction == PCMDIR_REC) { < try = c->feeder; < while (try != NULL) { < if (try->desc->type == FEEDER_ROOT) < return try->desc->out; < try = try->source; < } < return best; < } else < return c->feeder->desc->out; --- > return (c->direction == PCMDIR_REC)? best : c->feeder->desc->out;