linux/sound/isa/sscape.c
<<
>>
Prefs
   1/*
   2 *   Low-level ALSA driver for the ENSONIQ SoundScape
   3 *   Copyright (c) by Chris Rankin
   4 *
   5 *   This driver was written in part using information obtained from
   6 *   the OSS/Free SoundScape driver, written by Hannu Savolainen.
   7 *
   8 *
   9 *   This program is free software; you can redistribute it and/or modify
  10 *   it under the terms of the GNU General Public License as published by
  11 *   the Free Software Foundation; either version 2 of the License, or
  12 *   (at your option) any later version.
  13 *
  14 *   This program is distributed in the hope that it will be useful,
  15 *   but WITHOUT ANY WARRANTY; without even the implied warranty of
  16 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  17 *   GNU General Public License for more details.
  18 *
  19 *   You should have received a copy of the GNU General Public License
  20 *   along with this program; if not, write to the Free Software
  21 *   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
  22 */
  23
  24#include <linux/init.h>
  25#include <linux/err.h>
  26#include <linux/isa.h>
  27#include <linux/delay.h>
  28#include <linux/firmware.h>
  29#include <linux/pnp.h>
  30#include <linux/spinlock.h>
  31#include <linux/module.h>
  32#include <asm/dma.h>
  33#include <sound/core.h>
  34#include <sound/wss.h>
  35#include <sound/mpu401.h>
  36#include <sound/initval.h>
  37
  38
  39MODULE_AUTHOR("Chris Rankin");
  40MODULE_DESCRIPTION("ENSONIQ SoundScape driver");
  41MODULE_LICENSE("GPL");
  42MODULE_FIRMWARE("sndscape.co0");
  43MODULE_FIRMWARE("sndscape.co1");
  44MODULE_FIRMWARE("sndscape.co2");
  45MODULE_FIRMWARE("sndscape.co3");
  46MODULE_FIRMWARE("sndscape.co4");
  47MODULE_FIRMWARE("scope.cod");
  48
  49static int index[SNDRV_CARDS] = SNDRV_DEFAULT_IDX;
  50static char* id[SNDRV_CARDS] = SNDRV_DEFAULT_STR;
  51static long port[SNDRV_CARDS] = SNDRV_DEFAULT_PORT;
  52static long wss_port[SNDRV_CARDS] = SNDRV_DEFAULT_PORT;
  53static int irq[SNDRV_CARDS] = SNDRV_DEFAULT_IRQ;
  54static int mpu_irq[SNDRV_CARDS] = SNDRV_DEFAULT_IRQ;
  55static int dma[SNDRV_CARDS] = SNDRV_DEFAULT_DMA;
  56static int dma2[SNDRV_CARDS] = SNDRV_DEFAULT_DMA;
  57static bool joystick[SNDRV_CARDS];
  58
  59module_param_array(index, int, NULL, 0444);
  60MODULE_PARM_DESC(index, "Index number for SoundScape soundcard");
  61
  62module_param_array(id, charp, NULL, 0444);
  63MODULE_PARM_DESC(id, "Description for SoundScape card");
  64
  65module_param_array(port, long, NULL, 0444);
  66MODULE_PARM_DESC(port, "Port # for SoundScape driver.");
  67
  68module_param_array(wss_port, long, NULL, 0444);
  69MODULE_PARM_DESC(wss_port, "WSS Port # for SoundScape driver.");
  70
  71module_param_array(irq, int, NULL, 0444);
  72MODULE_PARM_DESC(irq, "IRQ # for SoundScape driver.");
  73
  74module_param_array(mpu_irq, int, NULL, 0444);
  75MODULE_PARM_DESC(mpu_irq, "MPU401 IRQ # for SoundScape driver.");
  76
  77module_param_array(dma, int, NULL, 0444);
  78MODULE_PARM_DESC(dma, "DMA # for SoundScape driver.");
  79
  80module_param_array(dma2, int, NULL, 0444);
  81MODULE_PARM_DESC(dma2, "DMA2 # for SoundScape driver.");
  82
  83module_param_array(joystick, bool, NULL, 0444);
  84MODULE_PARM_DESC(joystick, "Enable gameport.");
  85
  86#ifdef CONFIG_PNP
  87static int isa_registered;
  88static int pnp_registered;
  89
  90static struct pnp_card_device_id sscape_pnpids[] = {
  91        { .id = "ENS3081", .devs = { { "ENS0000" } } }, /* Soundscape PnP */
  92        { .id = "ENS4081", .devs = { { "ENS1011" } } }, /* VIVO90 */
  93        { .id = "" }    /* end */
  94};
  95
  96MODULE_DEVICE_TABLE(pnp_card, sscape_pnpids);
  97#endif
  98
  99
 100#define HOST_CTRL_IO(i)  ((i) + 2)
 101#define HOST_DATA_IO(i)  ((i) + 3)
 102#define ODIE_ADDR_IO(i)  ((i) + 4)
 103#define ODIE_DATA_IO(i)  ((i) + 5)
 104#define CODEC_IO(i)      ((i) + 8)
 105
 106#define IC_ODIE  1
 107#define IC_OPUS  2
 108
 109#define RX_READY 0x01
 110#define TX_READY 0x02
 111
 112#define CMD_ACK                 0x80
 113#define CMD_SET_MIDI_VOL        0x84
 114#define CMD_GET_MIDI_VOL        0x85
 115#define CMD_XXX_MIDI_VOL        0x86
 116#define CMD_SET_EXTMIDI         0x8a
 117#define CMD_GET_EXTMIDI         0x8b
 118#define CMD_SET_MT32            0x8c
 119#define CMD_GET_MT32            0x8d
 120
 121enum GA_REG {
 122        GA_INTSTAT_REG = 0,
 123        GA_INTENA_REG,
 124        GA_DMAA_REG,
 125        GA_DMAB_REG,
 126        GA_INTCFG_REG,
 127        GA_DMACFG_REG,
 128        GA_CDCFG_REG,
 129        GA_SMCFGA_REG,
 130        GA_SMCFGB_REG,
 131        GA_HMCTL_REG
 132};
 133
 134#define DMA_8BIT  0x80
 135
 136
 137enum card_type {
 138        MEDIA_FX,       /* Sequoia S-1000 */
 139        SSCAPE,         /* Sequoia S-2000 */
 140        SSCAPE_PNP,
 141        SSCAPE_VIVO,
 142};
 143
 144struct soundscape {
 145        spinlock_t lock;
 146        unsigned io_base;
 147        int ic_type;
 148        enum card_type type;
 149        struct resource *io_res;
 150        struct resource *wss_res;
 151        struct snd_wss *chip;
 152
 153        unsigned char midi_vol;
 154};
 155
 156#define INVALID_IRQ  ((unsigned)-1)
 157
 158
 159static inline struct soundscape *get_card_soundscape(struct snd_card *c)
 160{
 161        return (struct soundscape *) (c->private_data);
 162}
 163
 164/*
 165 * Allocates some kernel memory that we can use for DMA.
 166 * I think this means that the memory has to map to
 167 * contiguous pages of physical memory.
 168 */
 169static struct snd_dma_buffer *get_dmabuf(struct snd_dma_buffer *buf,
 170                                         unsigned long size)
 171{
 172        if (buf) {
 173                if (snd_dma_alloc_pages_fallback(SNDRV_DMA_TYPE_DEV,
 174                                                 snd_dma_isa_data(),
 175                                                 size, buf) < 0) {
 176                        snd_printk(KERN_ERR "sscape: Failed to allocate "
 177                                            "%lu bytes for DMA\n",
 178                                            size);
 179                        return NULL;
 180                }
 181        }
 182
 183        return buf;
 184}
 185
 186/*
 187 * Release the DMA-able kernel memory ...
 188 */
 189static void free_dmabuf(struct snd_dma_buffer *buf)
 190{
 191        if (buf && buf->area)
 192                snd_dma_free_pages(buf);
 193}
 194
 195/*
 196 * This function writes to the SoundScape's control registers,
 197 * but doesn't do any locking. It's up to the caller to do that.
 198 * This is why this function is "unsafe" ...
 199 */
 200static inline void sscape_write_unsafe(unsigned io_base, enum GA_REG reg,
 201                                       unsigned char val)
 202{
 203        outb(reg, ODIE_ADDR_IO(io_base));
 204        outb(val, ODIE_DATA_IO(io_base));
 205}
 206
 207/*
 208 * Write to the SoundScape's control registers, and do the
 209 * necessary locking ...
 210 */
 211static void sscape_write(struct soundscape *s, enum GA_REG reg,
 212                         unsigned char val)
 213{
 214        unsigned long flags;
 215
 216        spin_lock_irqsave(&s->lock, flags);
 217        sscape_write_unsafe(s->io_base, reg, val);
 218        spin_unlock_irqrestore(&s->lock, flags);
 219}
 220
 221/*
 222 * Read from the SoundScape's control registers, but leave any
 223 * locking to the caller. This is why the function is "unsafe" ...
 224 */
 225static inline unsigned char sscape_read_unsafe(unsigned io_base,
 226                                               enum GA_REG reg)
 227{
 228        outb(reg, ODIE_ADDR_IO(io_base));
 229        return inb(ODIE_DATA_IO(io_base));
 230}
 231
 232/*
 233 * Puts the SoundScape into "host" mode, as compared to "MIDI" mode
 234 */
 235static inline void set_host_mode_unsafe(unsigned io_base)
 236{
 237        outb(0x0, HOST_CTRL_IO(io_base));
 238}
 239
 240/*
 241 * Puts the SoundScape into "MIDI" mode, as compared to "host" mode
 242 */
 243static inline void set_midi_mode_unsafe(unsigned io_base)
 244{
 245        outb(0x3, HOST_CTRL_IO(io_base));
 246}
 247
 248/*
 249 * Read the SoundScape's host-mode control register, but leave
 250 * any locking issues to the caller ...
 251 */
 252static inline int host_read_unsafe(unsigned io_base)
 253{
 254        int data = -1;
 255        if ((inb(HOST_CTRL_IO(io_base)) & RX_READY) != 0)
 256                data = inb(HOST_DATA_IO(io_base));
 257
 258        return data;
 259}
 260
 261/*
 262 * Read the SoundScape's host-mode control register, performing
 263 * a limited amount of busy-waiting if the register isn't ready.
 264 * Also leaves all locking-issues to the caller ...
 265 */
 266static int host_read_ctrl_unsafe(unsigned io_base, unsigned timeout)
 267{
 268        int data;
 269
 270        while (((data = host_read_unsafe(io_base)) < 0) && (timeout != 0)) {
 271                udelay(100);
 272                --timeout;
 273        } /* while */
 274
 275        return data;
 276}
 277
 278/*
 279 * Write to the SoundScape's host-mode control registers, but
 280 * leave any locking issues to the caller ...
 281 */
 282static inline int host_write_unsafe(unsigned io_base, unsigned char data)
 283{
 284        if ((inb(HOST_CTRL_IO(io_base)) & TX_READY) != 0) {
 285                outb(data, HOST_DATA_IO(io_base));
 286                return 1;
 287        }
 288
 289        return 0;
 290}
 291
 292/*
 293 * Write to the SoundScape's host-mode control registers, performing
 294 * a limited amount of busy-waiting if the register isn't ready.
 295 * Also leaves all locking-issues to the caller ...
 296 */
 297static int host_write_ctrl_unsafe(unsigned io_base, unsigned char data,
 298                                  unsigned timeout)
 299{
 300        int err;
 301
 302        while (!(err = host_write_unsafe(io_base, data)) && (timeout != 0)) {
 303                udelay(100);
 304                --timeout;
 305        } /* while */
 306
 307        return err;
 308}
 309
 310
 311/*
 312 * Check that the MIDI subsystem is operational. If it isn't,
 313 * then we will hang the computer if we try to use it ...
 314 *
 315 * NOTE: This check is based upon observation, not documentation.
 316 */
 317static inline int verify_mpu401(const struct snd_mpu401 *mpu)
 318{
 319        return ((inb(MPU401C(mpu)) & 0xc0) == 0x80);
 320}
 321
 322/*
 323 * This is apparently the standard way to initailise an MPU-401
 324 */
 325static inline void initialise_mpu401(const struct snd_mpu401 *mpu)
 326{
 327        outb(0, MPU401D(mpu));
 328}
 329
 330/*
 331 * Tell the SoundScape to activate the AD1845 chip (I think).
 332 * The AD1845 detection fails if we *don't* do this, so I
 333 * think that this is a good idea ...
 334 */
 335static void activate_ad1845_unsafe(unsigned io_base)
 336{
 337        unsigned char val = sscape_read_unsafe(io_base, GA_HMCTL_REG);
 338        sscape_write_unsafe(io_base, GA_HMCTL_REG, (val & 0xcf) | 0x10);
 339        sscape_write_unsafe(io_base, GA_CDCFG_REG, 0x80);
 340}
 341
 342/*
 343 * Do the necessary ALSA-level cleanup to deallocate our driver ...
 344 */
 345static void soundscape_free(struct snd_card *c)
 346{
 347        struct soundscape *sscape = get_card_soundscape(c);
 348        release_and_free_resource(sscape->io_res);
 349        release_and_free_resource(sscape->wss_res);
 350        free_dma(sscape->chip->dma1);
 351}
 352
 353/*
 354 * Tell the SoundScape to begin a DMA tranfer using the given channel.
 355 * All locking issues are left to the caller.
 356 */
 357static void sscape_start_dma_unsafe(unsigned io_base, enum GA_REG reg)
 358{
 359        sscape_write_unsafe(io_base, reg,
 360                            sscape_read_unsafe(io_base, reg) | 0x01);
 361        sscape_write_unsafe(io_base, reg,
 362                            sscape_read_unsafe(io_base, reg) & 0xfe);
 363}
 364
 365/*
 366 * Wait for a DMA transfer to complete. This is a "limited busy-wait",
 367 * and all locking issues are left to the caller.
 368 */
 369static int sscape_wait_dma_unsafe(unsigned io_base, enum GA_REG reg,
 370                                  unsigned timeout)
 371{
 372        while (!(sscape_read_unsafe(io_base, reg) & 0x01) && (timeout != 0)) {
 373                udelay(100);
 374                --timeout;
 375        } /* while */
 376
 377        return sscape_read_unsafe(io_base, reg) & 0x01;
 378}
 379
 380/*
 381 * Wait for the On-Board Processor to return its start-up
 382 * acknowledgement sequence. This wait is too long for
 383 * us to perform "busy-waiting", and so we must sleep.
 384 * This in turn means that we must not be holding any
 385 * spinlocks when we call this function.
 386 */
 387static int obp_startup_ack(struct soundscape *s, unsigned timeout)
 388{
 389        unsigned long end_time = jiffies + msecs_to_jiffies(timeout);
 390
 391        do {
 392                unsigned long flags;
 393                int x;
 394
 395                spin_lock_irqsave(&s->lock, flags);
 396                x = host_read_unsafe(s->io_base);
 397                spin_unlock_irqrestore(&s->lock, flags);
 398                if (x == 0xfe || x == 0xff)
 399                        return 1;
 400
 401                msleep(10);
 402        } while (time_before(jiffies, end_time));
 403
 404        return 0;
 405}
 406
 407/*
 408 * Wait for the host to return its start-up acknowledgement
 409 * sequence. This wait is too long for us to perform
 410 * "busy-waiting", and so we must sleep. This in turn means
 411 * that we must not be holding any spinlocks when we call
 412 * this function.
 413 */
 414static int host_startup_ack(struct soundscape *s, unsigned timeout)
 415{
 416        unsigned long end_time = jiffies + msecs_to_jiffies(timeout);
 417
 418        do {
 419                unsigned long flags;
 420                int x;
 421
 422                spin_lock_irqsave(&s->lock, flags);
 423                x = host_read_unsafe(s->io_base);
 424                spin_unlock_irqrestore(&s->lock, flags);
 425                if (x == 0xfe)
 426                        return 1;
 427
 428                msleep(10);
 429        } while (time_before(jiffies, end_time));
 430
 431        return 0;
 432}
 433
 434/*
 435 * Upload a byte-stream into the SoundScape using DMA channel A.
 436 */
 437static int upload_dma_data(struct soundscape *s, const unsigned char *data,
 438                           size_t size)
 439{
 440        unsigned long flags;
 441        struct snd_dma_buffer dma;
 442        int ret;
 443        unsigned char val;
 444
 445        if (!get_dmabuf(&dma, PAGE_ALIGN(32 * 1024)))
 446                return -ENOMEM;
 447
 448        spin_lock_irqsave(&s->lock, flags);
 449
 450        /*
 451         * Reset the board ...
 452         */
 453        val = sscape_read_unsafe(s->io_base, GA_HMCTL_REG);
 454        sscape_write_unsafe(s->io_base, GA_HMCTL_REG, val & 0x3f);
 455
 456        /*
 457         * Enable the DMA channels and configure them ...
 458         */
 459        val = (s->chip->dma1 << 4) | DMA_8BIT;
 460        sscape_write_unsafe(s->io_base, GA_DMAA_REG, val);
 461        sscape_write_unsafe(s->io_base, GA_DMAB_REG, 0x20);
 462
 463        /*
 464         * Take the board out of reset ...
 465         */
 466        val = sscape_read_unsafe(s->io_base, GA_HMCTL_REG);
 467        sscape_write_unsafe(s->io_base, GA_HMCTL_REG, val | 0x80);
 468
 469        /*
 470         * Upload the firmware to the SoundScape
 471         * board through the DMA channel ...
 472         */
 473        while (size != 0) {
 474                unsigned long len;
 475
 476                len = min(size, dma.bytes);
 477                memcpy(dma.area, data, len);
 478                data += len;
 479                size -= len;
 480
 481                snd_dma_program(s->chip->dma1, dma.addr, len, DMA_MODE_WRITE);
 482                sscape_start_dma_unsafe(s->io_base, GA_DMAA_REG);
 483                if (!sscape_wait_dma_unsafe(s->io_base, GA_DMAA_REG, 5000)) {
 484                        /*
 485                         * Don't forget to release this spinlock we're holding
 486                         */
 487                        spin_unlock_irqrestore(&s->lock, flags);
 488
 489                        snd_printk(KERN_ERR
 490                                        "sscape: DMA upload has timed out\n");
 491                        ret = -EAGAIN;
 492                        goto _release_dma;
 493                }
 494        } /* while */
 495
 496        set_host_mode_unsafe(s->io_base);
 497        outb(0x0, s->io_base);
 498
 499        /*
 500         * Boot the board ... (I think)
 501         */
 502        val = sscape_read_unsafe(s->io_base, GA_HMCTL_REG);
 503        sscape_write_unsafe(s->io_base, GA_HMCTL_REG, val | 0x40);
 504        spin_unlock_irqrestore(&s->lock, flags);
 505
 506        /*
 507         * If all has gone well, then the board should acknowledge
 508         * the new upload and tell us that it has rebooted OK. We
 509         * give it 5 seconds (max) ...
 510         */
 511        ret = 0;
 512        if (!obp_startup_ack(s, 5000)) {
 513                snd_printk(KERN_ERR "sscape: No response "
 514                                    "from on-board processor after upload\n");
 515                ret = -EAGAIN;
 516        } else if (!host_startup_ack(s, 5000)) {
 517                snd_printk(KERN_ERR
 518                                "sscape: SoundScape failed to initialise\n");
 519                ret = -EAGAIN;
 520        }
 521
 522_release_dma:
 523        /*
 524         * NOTE!!! We are NOT holding any spinlocks at this point !!!
 525         */
 526        sscape_write(s, GA_DMAA_REG, (s->ic_type == IC_OPUS ? 0x40 : 0x70));
 527        free_dmabuf(&dma);
 528
 529        return ret;
 530}
 531
 532/*
 533 * Upload the bootblock(?) into the SoundScape. The only
 534 * purpose of this block of code seems to be to tell
 535 * us which version of the microcode we should be using.
 536 */
 537static int sscape_upload_bootblock(struct snd_card *card)
 538{
 539        struct soundscape *sscape = get_card_soundscape(card);
 540        unsigned long flags;
 541        const struct firmware *init_fw = NULL;
 542        int data = 0;
 543        int ret;
 544
 545        ret = request_firmware(&init_fw, "scope.cod", card->dev);
 546        if (ret < 0) {
 547                snd_printk(KERN_ERR "sscape: Error loading scope.cod");
 548                return ret;
 549        }
 550        ret = upload_dma_data(sscape, init_fw->data, init_fw->size);
 551
 552        release_firmware(init_fw);
 553
 554        spin_lock_irqsave(&sscape->lock, flags);
 555        if (ret == 0)
 556                data = host_read_ctrl_unsafe(sscape->io_base, 100);
 557
 558        if (data & 0x10)
 559                sscape_write_unsafe(sscape->io_base, GA_SMCFGA_REG, 0x2f);
 560
 561        spin_unlock_irqrestore(&sscape->lock, flags);
 562
 563        data &= 0xf;
 564        if (ret == 0 && data > 7) {
 565                snd_printk(KERN_ERR
 566                                "sscape: timeout reading firmware version\n");
 567                ret = -EAGAIN;
 568        }
 569
 570        return (ret == 0) ? data : ret;
 571}
 572
 573/*
 574 * Upload the microcode into the SoundScape.
 575 */
 576static int sscape_upload_microcode(struct snd_card *card, int version)
 577{
 578        struct soundscape *sscape = get_card_soundscape(card);
 579        const struct firmware *init_fw = NULL;
 580        char name[14];
 581        int err;
 582
 583        snprintf(name, sizeof(name), "sndscape.co%d", version);
 584
 585        err = request_firmware(&init_fw, name, card->dev);
 586        if (err < 0) {
 587                snd_printk(KERN_ERR "sscape: Error loading sndscape.co%d",
 588                                version);
 589                return err;
 590        }
 591        err = upload_dma_data(sscape, init_fw->data, init_fw->size);
 592        if (err == 0)
 593                snd_printk(KERN_INFO "sscape: MIDI firmware loaded %d KBs\n",
 594                                init_fw->size >> 10);
 595
 596        release_firmware(init_fw);
 597
 598        return err;
 599}
 600
 601/*
 602 * Mixer control for the SoundScape's MIDI device.
 603 */
 604static int sscape_midi_info(struct snd_kcontrol *ctl,
 605                            struct snd_ctl_elem_info *uinfo)
 606{
 607        uinfo->type = SNDRV_CTL_ELEM_TYPE_INTEGER;
 608        uinfo->count = 1;
 609        uinfo->value.integer.min = 0;
 610        uinfo->value.integer.max = 127;
 611        return 0;
 612}
 613
 614static int sscape_midi_get(struct snd_kcontrol *kctl,
 615                           struct snd_ctl_elem_value *uctl)
 616{
 617        struct snd_wss *chip = snd_kcontrol_chip(kctl);
 618        struct snd_card *card = chip->card;
 619        register struct soundscape *s = get_card_soundscape(card);
 620        unsigned long flags;
 621
 622        spin_lock_irqsave(&s->lock, flags);
 623        uctl->value.integer.value[0] = s->midi_vol;
 624        spin_unlock_irqrestore(&s->lock, flags);
 625        return 0;
 626}
 627
 628static int sscape_midi_put(struct snd_kcontrol *kctl,
 629                           struct snd_ctl_elem_value *uctl)
 630{
 631        struct snd_wss *chip = snd_kcontrol_chip(kctl);
 632        struct snd_card *card = chip->card;
 633        struct soundscape *s = get_card_soundscape(card);
 634        unsigned long flags;
 635        int change;
 636        unsigned char new_val;
 637
 638        spin_lock_irqsave(&s->lock, flags);
 639
 640        new_val = uctl->value.integer.value[0] & 127;
 641" id="L6line"83>sscape-> 630{
6ata = 0;
ERR         * give it 5 s6 class="s6ef">ret;
 603 544
 496        set_host_mode_unsafe(s->dev);
a> < 0) {
 641" id="L6line"83>sscape name="L6ot;);
 class="coms 641" id="L6line"83>sscapess="sref"ef">ret;
 641" id="L6line"83>sscap549"> 5496/a>        }
an cperfn_m 8anrsssize);
 opetring"> 8an9"> 509 "L60a09 is 8RR closeR ?he new upload and tell us that it has6l->51"> 551
 6036nit_fw);
value[0] = s-&-> 640     if ( 553
 635     >integer._skip_line" name="L635"> 63>_skip_line" ned char 6et == 0)
io_ba6e, 100);
 635     >in" id="L607" claa hrehref="ta" class="sref">data = set_host_mode_unsafe(s>s->>sgt;<.c#L626" id="L626" class="line"e name="L657"> 557
data = set_host_mode_unsafe(s>s-> 640   >sgt;<.c#L626" id="L626" class="line"ess="sref" & 0x10)
data = set_host_mode_unsafe(s>s->   >sgt;<.c#L626" id="L626" class="line"SMCFGA_RE6, 0x2f);
data = set_host_mode_unsafe(s>s-> 640   >sgt; 560
value[0] = s-&-&lass="line" name="L636"> 636        unsigned char  63>_skip_line" ned ef="+code=_release_dma" class="6" name="L662"> 562
data 641" id="L6line"83>sscapef">data<6a> > 7) {
         * give it 5 s6ss="sref"6KERN_ERR
 603);
 name="L496"> 496         name="L496t_host_mode_unsafe" class="sref">set_host_mode_unsafe(s-> 5686/a>        }
 624        spin_unlock_irqrestore(&s->lock,  569
 635        int ret;
 571}
 572
s_  uss="sref">chip = [0] = -&-&lif (/*
type = _kcontrol *
in-&laa href="+code=KERN_INFO" c="coring">"sscape: MIDI firmware loaded $s="commen6"> */
         604static int -> 614stag0"> 550         614static int  577{
 628staref="+c0         628static int  5686">card);
NULL;
6ame[14];
 601err;
 602         * give it 5 s6" name="L682"> 582
 secIRQs NFO6ersion);
         * give it 5 s6"he Sound684"> 584
 575dev);
 628sta5_mentni6scapeue[0] =  = ode_" nfigass="sref">s = ode_" nfignlock8" id="L628" class="line" ode=uinfo" class="s"line" ode=ref">s8" id="L628" class=odeine" name="L610=rqf">lo name="L575"> 575 < 0) {
 5686ersion);
err;
s 5906/a>        }
size);
6rr == 0)
sinte2="L635" class="lfgass="sref">s     ="L635" class="ARRAY_SIZEass="sref">ss 575,
l->s 575s 595
sinte2="L635" class="lfgass="sref">s     ="L635" class="ARRAY_SIZEass="sref">ss 575 597
l->s 575 5686ef">err;
s 599}
 600
/*
sctl,
 601uinfo)
anrs>anrthe new upload and tell us that it has7 name="L676"> 606{
an9givn cportsclass="comment">         * give it 5 s7ELEM_TYPE7INTEGER;
 575c7unt = 1;
 628sta5_mentni6scapeue[0] = s 633        struct  604statwss_i0    o name="L575"> 575 = 0;
m7x = 127;
 634        unsigned long     7   return 0;
s 612}
 636      lin36"    >inteed long  613
kctl,
 638        spin_lock_irqsave(&s->lock, uctl)
 616{
 641" id="L6line"83>ssca7lass="sre7">kctl);
an9original OSS drivnr, name="L641"> 641" id="L6line"83>ssca7class="sr7f">card;
isheet I c#Lno     lly 5L509"  name="L641"> 641" id="L6line"83>ssca7lass="sre7">card);
         * give it 5 s7lass="sre7">flags;
 575 621
sHOST_CTRL_I"t_host_mode_unsafe" class="sref">set_host_mode_unsafe(s-)       if78) !       if (don name="L635"> 63>don nsigned long 7idi_vol;
flags);
s        sODIE_ADDR_I"t_host_mode_unsafe" class="sref">set_host_mode_unsafe(s-)       iffteed long     7   return 0;
s 626}
don name="L635"> 63>don nsigned long  627
kctl,
suctl)
set_host_mode_unsafe(s 630{
skctl);
set_host_mode_unsafe(scard;
7">card);
don name="L635"> 63>don nsigned long flags;
change;
sODIE_ADDR_I"t_host_mode_unsafe" class="sref">set_host_mode_unsafe(s-)ned long sODIE_ADDR_I"t_host_mode_unsafe" class="sref">set_host_mode_unsafe(s-)       if9f) !   x0a    if ( 637
don name="L635"> 63>don nsigned long  639
sODIE_ADDR_I"t_host_mode_unsafe" class="sref">set_host_mode_unsafe(s-)ned long [7] & 127;
sODIE_ADDR_I"t_host_mode_unsafe" class="sref">set_host_mode_unsafe(s-)       if9f) !   x0e    if (->7don name="L635"> 63>don nsigned long 7ata = 0;
ret;
sODIE_ADDR_I"t_host_mode_unsafe" class="sref">set_host_mode_unsafe(s-)ned long  544
s        sODIE_DATA_I"t_host_mode_unsafe" class="sref">set_host_mode_unsafe(s-)ned long dev);
set_host_mode_unsafe(uinf!&lass="line" namerSCAPE_VIV" class="sref">srSCAPE_VIV"nsig0           d="L558" class="lass="sref">sdon name="L635"> 63>don nsigned long ret;
set_host_mode_unsafe(s 5497/a>        }
 496     activate_ad1845e="L496t_host_mode_unsafe" class="sref">set_host_mode_unsafe(s-ned long size);
 551
set_host_mode_unsafe(uinf<        srSCAPE_VIV"nsig    if (7nit_fw);
 604statwss_i0     += 4ned long  553
flags);
s         496      line" reade="L496t_host_mode_unsafe" class="sref">set_host_mode_unsafe(s>s-> 496      line" href="="L496t_host_mode_unsafe" class="sref">set_host_mode_unsafe(s>s->sio_ba7e, 100);
 557
 575sss 604statwss_i0    o0      if80) <       if ( 560
 624        spin_unlock_irqrestore(&s->lock,  562
,  638        spin_lock_irqsave(&s->lock, data<7a> > 7) {

);
 604statwss_i0    o0      if80) !       if (don name="L635"> 63>don nsigned long  5687/a>        }
 569
 604statwss_i0     + 2) <   xff    if (ret;
don name="L635"> 63>don nsigned long  571}
 572
s         496      line" reade="L496t_host_mode_unsafe" class="sref">set_host_mode_unsafe(s>s->/*
 496      line" href="="L496t_host_mode_unsafe" class="sref">set_host_mode_unsafe(s>s->s, 
 */
 604statwss_i0    o0      if80) !       if ()
set_host_mode_unsafe(uinf 577{
 5687">card);
s         496      line" reade="L496t_host_mode_unsafe" class="sref">set_host_mode_unsafe(s>s->NULL;
 496      line" href="="L496t_host_mode_unsafe" class="sref">set_host_mode_unsafe(s>s->s7ame[14];
 575err;
sss 582
 604statwss_i0    o0      if80) <       if (7ersion);
 584
 624        spin_unlock_irqrestore(&s->lock, dev);
,  < 0) {
 638        spin_lock_irqsave(&s->lock, ,
 5687ersion);
err;
 641" id="L6line"83>ssca7590"> 5907/a>        }
 641" id="L6line"83>ssca75class="s7">size);
 6037rr == 0)
 636      lin36"    >in1ck, ,
don name="L635"> 63>don nsigef="+code=_release_dma" class="75lass="sr795"> 595
 624        spin_unlock_irqrestore(&s->lock, );
 636      lin36"    ck,  597
 5687ef">err;
 599}
 641" id="L6line"83>ssca8" name="L800"> 600
         * give it 5 s8ss="comme8t">/*
 641" id="L6line"83>ssca8 3="comme8tr == 0)
 641" id="L6line"83>ssca8 4="comme8tot;,
         * give it 5 s8s5="comme8tt;> 10);
 603uinfo)
spin_unlockss=mpu401scape href="+code=soumpuode=card" classmpuf">lo name="L603"> 603);
spin_unlocverify=mpu401t_host_mode_unsafe" mpuode=card" classmpuf">lo  if (c8unt = 1;
type = scapeaa href="+code=KERN_INFO" cr" cla:s="comme=ebled, ring">"sf ( = 0;
"sock, m8x = 127;
 = ,     8   return 0;
 612}
 613
kctl,
uctl)
 616{
 641" id="L6line"83>ssca8lass="sre8">kctl);
 602         * give it 5 s8class="sr8f">card;
 603card);
 628sta5_mentni6scapeue[0] = spin_unloccreate_mpu401nlockde=sscape_midi_put" class=ame="L632"> 632        struct snd>s8" id="L628" class=mennumass="sref">ssnd> name="L603"> 603m8">flags;
ssnd>s8" id="L628" class=odeine" name="L610=rqf">lo name="L575"> 575 621
flags);
 633        struct  633    struct          = ref"_e" name="L633"> 633  > = ref"_e" name="Lt_host_mode_unsafe" =snd_card" class="sref">sndock, 8idi_vol;
 632    raw  632raw ,  626}
chip mpu401_uart_  ut_host_mode_unsafe" =snd_card" class="sref">snd>s->ssnd>t;ssnd>gt; 627
l, _irqrestore" class="raw  632raw , kctl,
uctl)
spin_unlockss=mpu401scape href="+code=soumpuode=card" classmpuf">l0         632raw (&iass="sref">sict ,  630{
lrestore(& 628staopet_in"L6f">l0        , kctl);
lrestore(& 628staopet_out"L6f">l0        , card;
lrestore(&iass="sref">sict <0         633    struct , 8">card);
flags;
spin_unlocinitiadise_mpu401t_host_mode_unsafe" mpuode=card" classmpuf">lock, ;
 637
 639
 641" id="L6line"83>ssca8s="sref">8ata = 0;
 602 641" id="L6line"83>ssca8s="sref">8ef">ret;
 641" id="L6line"83>ssca8sass="sre844"> 544
 6extra bits by overr 641" id="L6line"83>ssca8sass="sre8f">dev);
 6CS4231 callbackclass="comment">         * give it 5 s8ename="L68a> < 0) {
 603 628sta5_mentni6scapeue[0] = spin_unloccreate_ad1845nlockde=sscape_midi_put" class=ame="L632"> 632        struct snd>s" id="L63ue[0] = ssnd>gt;ret;
l, 8" id="L628" class=mma1ref">spin_unlocmma1f">l, 8" id="L628" class=mma2ref">spin_unlocmma2f">lo name="L575"> 575 5498/a>        }
size);
 633        struct  633    struct          = ref"_e" name="L633"> 633  > = ref"_e" name="Lt_host_mode_unsafe" =snd_card" class="sref">sndock, ->851"> 551
spin_unlockss=wssstruct , 8nit_fw);
 553
 == 0)
 633    struct <_mode_unsafe(uin  if (io_ba8e, 100);
 557
 641" id="L6line"83>ssca8SMCFGA_RE8, 0x2f);
 ref"s name="L641"> 641" id="L6line"83>ssca8Sass="sre860"> 560
 641" id="L6line"83>ssca8S->8>flags);
 641" id="L6line"83>ssca8S="sref">862"> 562
 secref"s socforce2itclass="comment">         * give it 5 s8"class="s8 &= 0xf;
 603data<8a> > 7) {
 633    struct <_mode_unsafe(s
);
 5688/a>        }
srSCAPE_VIV"nsigef="+code=_release_dma" class="8" name="L869"> 569
ssnd += 4ned long ret;
 571}
872"> 572
/*
 */
spin_unlockss=wss_createt_host_mode_unsafe" =snd_card" class="sref">snd>s->ssnd>s-1>t;l, d="L628" class=mma1ref">spin_unlocmma1f">l, d="L628" class=mma2ref">spin_unlocmma2f">l>gt;)
spin_unlocWSS_HWSHARE_DMA1f">l, _irqrestore" class="=hicode=card" class=hicct ,  577{
 5688">card);
 634        unsigned long NULL;
sserr;
 633    struct <_mode_unsafe(uinf!&lass="line" namerSCAPE_VIV" class="sref">srSCAPE_VIV"nsig  if ( 582
 641" id="L6line"83>ssca8s="sref">8ersion);
 602 641" id="L6line"83>ssca8"he Sound884"> 584
 641" id="L6line"83>ssca8"="commen8f">dev);
         * give it 5 s8csion\n&q8a> < 0) {
 627
l, _irqrestoass="eremce_u1eref">spin_unlockss=wMA1f">l, _irqrestore" class="=hicode=card" class=hicct ret;
 638        l, _irqrestore" clasline"633"> 633  MHz_unlock_irqrestores->loc8.c#L639" 8d="L639" class="lin7 cla8s="s789n = 0;
spin_unlockss=wMA1f">l, _irqrestore" clas=uinfo" class="samentce_CLOCKf">l, _irqrestomentce_CLOCKclas=u0x2hredass="sref">s 6418 id="L6line"83>ssca7590"8 590789flags;
 624        l, _irqrestore" clasline"633"> 633  MHz_unlock_irqrestores->loc8.c#L621" i id="L6line"83>ssca75cla8s="s789">err;
eref">spin_unlockss=wMA1f">l, _irqrestore" class="=hicode=card" class=hicct  603789> 612}
);
dev);
spin_unlockss=wMA1f">l, _irqrestore" clas=u0spin_unlocWSS_HWSHARE_/aass=pcmstruct    ref="+code=flags" c7ssio8\n&q789rsion)
 627
type = scapeaa hrNod="L5 classCINFO" cr" cla:s="comme=ebled, ring">"sfid="L590"8class="line" name="7;68"8 568789">ret;
"soc9.c#L639" 9d="L639" class="lin8 nam9="L5890n = 0;
s 6419 id="L6line"83>ssca8" na9e="L890flags;
  9      * give it 5 s8ss="9omme890> 571}
 6419 id="L6line"83>ssca8 3="9omme890>card;
spin_unlockss=wMA1f">l, _irqrestore" class="=hicode=card" class=hicct  6419 id="L6line"83>ssca8 4="9omme890sion);
  9      * give it 5 s8s5="9omme890 > 7) {
type = scapeaa hrNodmixes5 classCINFO" cr" cla:s="comme=ebled, ring">"s9name="L609"> 603
"soc9.7me="L609"ef="+code=flags" c7ssio9"sre890rsion)
s 627
c89nt = 1;
l, _irqrestore" clasline"633"> 633  s=someonf">l, _irqrestos=someon  >(         = 0;
spin_unlockss=wMA1f">l, _irqrestore" clas=u0sp>spin_unlockss=NULLf">l, _irqrestoNULLclass="=hicode=card" class=hicct , m89 = 127;
err;
type = scapeaa hrNodtimes5 classCINFO" cr" cla:s="comme=ebled, ring">"s9uRmme=ebled, ring0yref">8">card);
spin_unlockss=mumpuode=card" classmpuf"1" id24        ret;
set_host_mode_unsafe(;
9ctl)
{
k9tl);
 633    struct <_mode_unsafe(uinf!&lass="line" namerSCAPE_VIV" class="sref">srSCAPE_VIV"nsig  if (9ard;
 632        stl_ad3st_mode_unsafe" =snd_card" class="sref">snd>sc9rd);
spin_unlockss=mpu4stl_new" _irqrestore" clasline"63ct <, _irq4stl>spin_unlockss=ct <, _irq4stl>s->m8">f9ags;
 621
slo name="L575"> 579<92imes5 classCINFO" cr" cla:s="comme=ebled, ring">"s9uRmme=ebled, ring0yref">8">c" id=ss=pr"controlb5L471" id="L471" /is7/sscape.c#L639" id="Le.ccief"_e" na9e="L633"> 633  > = r9f"_e"92puode=card" classmpuf"1" id24        ret;
 632   9raw <92="sref">set_host_mode_unsafe(f9ags);
;
, 9ctl)
spin_unlocode=err" class="8"8l->851"> 551
l9 _irqrestore" 4>;
kctl,
 632raw (&aa href="+code=spin_unss="e28" class="lin7ess="8nd/is87sscape.c#L56111111111br9et_in"L629"> 628staopet_in"L6f9>l0         628staopet_out"L6f9>l0     4>;
iass="sref">sict <0         933   9struct , );
spin_unloci9itiad93 14.31818 MHz, becausecwe mg  if (lo9k,  641ca8s="sref">8e,8 3="c if (dev);
 937
 602    9e" class=9erect ,  603 628sta5_mentni6scapeue[0] = s3"> 633    struct <_mode_un9f="so8nd/9s8/sscape.c#L626" id="L696" cl9ss="li7ess="sref">m8">f9ags;
size);
 633        struct  633    struct          = 9="L621" c9ass="lin8e->8 624siio_lo9);
 624sio8nd <9 0) {948mes5 classCIn_unloccr=value" class="erect <  if ( 5688">card);
<9t 9nd>s" id="L63u, spin9unloc950>s" id="L63ulock>, lo name="L575"> 579<9pan cla8549"> const"charne8lass="sre8">si75">ass="sref">lock75"> 633  > = r9f"_e"95890flags;
spi9_unlo9kss=wssstruct 1818 MHz, becausecwe mg  if (8ni9_fw);
   9 class="sa hrc ode=ct   95Tan9in"L6574ockmfrequency2on t> 602<* c657641" i="Ld controlSound8a href="ommen8f">dev);
    9d="L592" 9lass=""line"633"> 633oL621" i id="L6li 6linst_84">oL struct 8">c="sref">8eL471" id="L471" /is7/sscape.c#L639" id="Le.cci>, 100);
9a href="so8nd/is85sscape9c#L5895f">l, _irqrestore" class="=hicodeio_m8">f9ags;
 557<9a>
 621
m8">f9ags;
sssca8grab  We w0x3>s7;lxb5L471" id="L47alue" class="erect <0         = {
{
8ni9so8nd/is86sscape.c#L533"9id="L964">l, _irqrestore{
k9tl);
 633    struct <_mode_unsafeoL621" i id="L6li 6linst_84">oL struct 8">c="sref">8eL471" id="L471" /is7/sscape.c#L639" id="Le.cciafe(<9 hc ode=uinfo" class="sh9 ode=9sig0!&lass="line" nametore" class="=hicodeo8nd 633    struct <_mode_unsafe 621
sssca8grab  We w0x3>s7;lxb5L471" id="L47a33    struct <_mode_unsafesnd>t; 557<9"L5breakchar srSCAPE_VIV"nsig  if (oL621" i id="L6lipreode=e_84">oL =  = l, _irqrestore" class="=hicode=c9+code=_re9ease_dma" class="8"="sre9">8729> 572
 602<* Grab 6linDMArchannelommen8f">dev);
 602    90=rqf">l,9d="L628" class=mma1ref">9pin_u97lags" c8sass="sre8   return 0;
card; 6linst_dmrcard;dmr8">c="sref">8eL471" id="L471" /is7/sscape.c#L639" id="Le.cciWSHARE_DM91ref">spin_unlocWSS_HWSH9RE_DM91f">l, _irqrestorecard" class=hicct m8">f9ags;
 597{
,  621
sssca8grab DMAr3>s7;db5L471" id="L47alue" class="erecdmref8f">card;dmroL621" i id="L6lipreode=e_84">oLs981 id="L-t_mode_unsafe" ENODEVtype = s<9apcmstruned long ;
(uin9!&las98so7nd/is79 630{
 595
 61" /is7/sscape.c#L639" id="Le.cci code=_re9582
{
dono8nd/9s81ss91pe.c#L637" id="L637" class="lin8las9=io_be=e9s81ss91pe.c#L6io_be=e.c#Lis83sscape.c#L490"t <0        l,9 id="L536" cla 1#L514"ee9eeeee988f">9ctl)
l, _irqrestore" class="=hicode641" i=so8nd/9s81ss91pe.c#L6641" i=so8nd/m8">f9ags;
spin_unloc9ss=wM91f">l, _irqrestore" cl3sscape.c#L490"t/a>,  621
ss7;xb5L471" id="L47a33    struct <_mode_unsafes->l, 9irqre9tomentce_CLOCKclas=u0x"sref">srSCAPE_VIV"nsig  if ("sock, m8x = 129stores->card;preode=e_dmr+code=flags" c8="sref">m8x = 129sa>(eref">spin_unloc9ss=wM99so7nd/is79 63e_unsafe" ENODEVtype =  69399ict <0         9ape, 9a 8ref="+code=flags" c7;9 K8s\995o7nd/is79 63"sre8>flags);
 == 0)
uin  if (io_ba8esi75">ass="sref">lock75">8">c"ediaFX/="sreFXL471" id="L47e=flags" c8="sref">m8x = 129s&q8a> &l9="s href="so8nd/is8/ssca9e.c#L929" id="L558" cla clasf="so8nd/is87sscape.c#L592defaultef=9ERN_ER>ty9e = scap9aa hr99val" cl8ass="sref8>EAGAIN;
io_ba8e = scap10o8n>10o8ss=pcmstruct si75">ass="sref">lock75">8">cSa>       L471" id="L47e=f/pre>de=err" class="8ef">io_ba8el, 10os=>10o id="L4t_mode_unsafe" portass="sref">ssnd += 4ned10o2nd/is8l10ounlo ode=uinfo" class="10oun>10o2al" cl8ass="sref8>EAGAIN;
io_ba8eeref">spin_unloc10oce>10o it 5 s8ss="9omme890> 571}
ass="sref">lock75">8">cSa>        PnPL471" id="L47e=flags" c8="sref">m8x = 1210o4nd/is8l10oicct  610oic>10opuode=card" classmpuf portass="sref">ssnd += 4ned10o5nd/is8l10o 8ref="+code=flags" c7;10o 8>10o5al" cl8ass="sref8>EAGAIN;
 5688/a>      10o6nd/is8l10o.c#L624e..c#L584" 8d="L10o.c>10oss="lin7;he 8ound789pe.
ass="sref">lock75">8">cSa>        d="LL471" id="L47e=flags" c8="sref">m8x = 1210o7nd/is8l10oclas=u0spin_unlocWSS_HW10ocl>10o    10o9" id="L558" ref="so8nd/is87sscape.c#L56111111111br10o9nd/is8l10o = scap10o10of">l, _irqrestore" cl3sscape.c#L490"75">ass="sref">lock75">8">cunknown Sa>       L471" id="L47e=f/is87sscape.c#L56111111111br1018nd/is8l10fo" classhrc ode=ct 10fo   spin_unloc10re">10f1 id="L-t_mode_unsafe" ENODEVtype =  621"> 6>
 6s="l_ss="sref">ss7;sme="L 641" iedwill0x3>s7;x,8 3="c IRQ=3>s7;d, DMAr3>s7;db5L471" id="L47aags;
spin_unlo10ass>10fpuode=card" classmpuf"1" id24<3sscape.c#L490"75">ass="sref">lock75">spin_unlockss=wss_createt_host_mo[loccreate_mpu401nl9s81ss91pe.c#L61nlaa h], Re" class="erecdmref8f">card;dmr10f789sion);
,
ssca8ps=lsus garbage ="soommen8f">dev);
10f    10f9nd/is8l10=uinfo" class="sref">uin10=ui>10f9o7nd/is79 630{
 == 0)
spin_unlockss=wss_createt_host_mo[loccreate_mpu401nl9s81ss91pe.c#L61nlaa h]1" /is7/sscape.c#L639" id="Le.cc1028nd/is8l10ass="eretictl_ad32"> 63210ass>10as">l, _irqrestorecard" class=hicirq_cfg9s81ss91pe.c#L6irq_cfg.c#Lap86sscape.c#L605" iNVALID_IRQ9s81ss91pe.c#L6iNVALID_IRQa href="so8nd/is85sscape.c#L596switch10a1nd/is8l10<, _irq4stl>spin_unlocks10<, >10aomentce_CLOCKclas=u0x"sref">srSCAPE_  i9,  621
ss7;db5L471" id="L47alue" class="erecockss=wss_createt_host_mo[loccreate_mpu401nl9s81ss91pe.c#L61nlaa h]1" /is7/sscape.c#L639" id="Le.cc1022nd/is8l109s82ss9ape.c#L5611111111109s8>10a        XI6>
XI6+code=flags" c8="sref">m8x = 1210a3nd/is8l10=rqf">lo name="L575"> 5710=rq>10a it 5 s8ss="9omme890>    card;preode=e_dmr+code=flags" c8="sref">m8x = 1210a4nd/is8l10e="L633"> 633  > = r10e=">10a 572
 632   10aw >10a789sion);
);
dompu_irq_cfg9s81ss91pe.c#L6mpu_irq_cfg.c#Lape.c#L588" id="L63" iirq_config9s81ss91pe.c#L63" iirq_config == 0)
spin_unlmpu_irq9s81ss91pe.c#L6mpu_irqt_mo[loccreate_mpu401nl9s81ss91pe.c#L61nlaa h]1" /is7/sscape.c#L639" id="Le.cc1027nd/is8l10"erect , 10a7">l, _irqrestorecard" class=hicmpu_irq_cfg9s81ss91pe.c#L6mpu_irq_cfg.c#Lap86sscape.c#L605" iNVALID_IRQ9s81ss91pe.c#L6iNVALID_IRQa href="so8nd/is85sscape.c#L596switch10a8nd/is8l10_MPU401uinfo" class="sMP10_MP>10aMPU401>snd>t;{
 621
ss7;db5L471" id="L47alue" class="erecmpu_irq9s81ss91pe.c#L6mpu_irqt_mo[loccreate_mpu401nl9s81ss91pe.c#L61nlaa h]1" /is7/sscape.c#L639" id="Le.cc1029nd/is8l10+codeodeine" name="L610=10+co>10af">l, _irqrestore" cl3sscape.c#L490"VIV"nsig  if (XI6>
XI6+code=flags" c8="sref">m8x = 121038nd/is8l10>,
    card;preode=e_dmr+code=flags" c8="sref">m8x = 121031nd/is8l1032"> 632raw 10>1 id="L-t_mode_unsafe" ENODEVtype =  628staopet_in"L6f10"> >10>890flags;
 628staopet_out"L6f10> 6>10>ss=wssstruct 1818 MHz, becausecwe mg  if (4nd/is8l10e_f">iass="sref">s10>e.c#L593" id="L5" id="L6p.c#L602" id* Tellica8son-bo="L 64f="+s w" namca8irr="de=rcesme="L(ISounnkedmif (5nd/is8l10struct , 10>Tan9in"L6574ockmfrequency2on t> 602<* I=c653>ssca8b"L6uref"s nout a ="sosheecomme So many magic values!)mif (6nd/is8l10e_mpu401ref">spin_unloci10e_m>10> 14.31818 MHz, becausecwe mus  ses=lt on t> 602    10>7nd/is8l10k, ret;
 6l, _irqrestore" clasline"633"> 633  MHz_unlock_irqr10>8nd/is8l10e.c#L556e.c#L626" id="L610e.c>10>/span>);
10>9o7nd/is79 630{
spin_unlGA_SMCFGA_REG9s81ss91pe.c#L6GA_SMCFGA_REG.c#Lea0x2ee"633"> 633  MHz_unlock_irqr1048nd/is8l10erect , spin_unlGA_SMCFGB_REG9s81ss91pe.c#L6GA_SMCFGB_REG.c#Lea0x0ockss=wMA1f">l, _irqrestore" clas10e1nd/is8l10s8/sscape.c#L626" id="L610s8/>10eaass=pcmstruct dev);
10ee.c#L593" id="L5" id="L6p.c#L602" id* on t> 602    1045nd/is8l10#L574" id="L574" classis10#L5>10e5o7nd/is79 630{
spin_unlGA_DMACFG_REG9s81ss91pe.c#L6GA_DMACFG_REG.c#Lea0x5ockss=wMA1f">l, _irqrestore" clas10e6nd/is8l10575" id="L575" cl"  try 10575>10e/is79sscapne" name="L492">dodma_cfg9s81ss91pe.c#L61ma_cfg.c#Lode4" cla 1#L514"eeeeeeee"s="line" name="L603"> 603data<8a> > 7) {
l, _irqrestore" clas10e7nd/is8l10);
spin_unlGA_DMAA_REG9s81ss91pe.c#L6GA_DMAA_REG.c#Leateref">spin_unldma_cfg9s81ss91pe.c#L61ma_cfg.c#Lckss=wMA1f">l, _irqrestore" clas10e8nd/is8l10 it 5 s8ename="L68a> <10 it>10e8ags" c8sass="sre8   return so8nd/_write_unsaf/9s81ss91pe.c#L637" id_write_unsaf/spin_unlGA_DMAB_REG9s81ss91pe.c#L6GA_DMAB_REG.c#Lea0x2ockss=wMA1f">l, _irqrestore" clas10e9nd/is8l10"+code=snd_card" class="10"+c>10e9ass=pcmstruct spin10628>1062is79sscapne" name="L492">dompu_irq_cfg9s81ss91pe.c#L6mpu_irq_cfg.c#La|86sscape.c#L605" mpu_irq_cfg9s81ss91pe.c#L6mpu_irq_cfg.c#Laass=ass="2kss=wMA1f">l, _irqrestore" clas1051nd/is8l10ma2f">lo name="L575"> 5710ma2>1061is79sscapne" name="L492">do class="sref">lock>, spin_unlGA_HMCTL_REG9s81ss91pe.c#L6GA_HMCTL_REGa href">reta0xF7kss=wMA1f">l, _irqrestore" clas1052nd/is8l10e="L633"> 633  > = r10e=">1062s=wssstruct torecard" class=hicjoystia s="line" name="joystia t_mo[loccreate_mpu401nl9s81ss91pe.c#L61nlaa h]1ss=wMA1f">l, _irqrestore" clas1053nd/is8l10i_put" class=wssref">spi10i_p>106 it 5 s8ss="9omme890> 571}
lock>, l, _irqrestore" clas1054nd/is8l10_fw);
spin_unlGA_HMCTL_REG9s81ss91pe.c#L6GA_HMCTL_REGa hreateref">spin_unl class="sref">lock>, l, _irqrestore" clas1055nd/is8l10 class="sa hrc ode=ct 1065o7nd/is79 630{
spin_unlGA_INTCFG_REG9s81ss91pe.c#L6GA_INTCFG_REG.c#Lea0xf0o|asscape.c#L605" mpu_irq_cfg9s81ss91pe.c#L6mpu_irq_cfg.c#Lckss=wMA1f">l, _irqrestore" clas1056nd/is8l10TECTct , 106/is79sscapne" name="L492">dono8nd/_write_unsaf/9s81ss91pe.c#L637" id_write_unsaf/l, _irqrestore" clas1057nd/is8l10lass=""line"633"> 633106    doGA_CDCFG_REG9s81ss91pe.c#L6GA_CDCFG_REG.c#Lea0x09o|asscape.c#L605" DMA_8BIT9s81ss91pe.c#L6DMA_8BITass=pcmstruct 106MPU401>snd>t;card;dmr
10ef4231 works only6in CS4248 5L5pc#Lbi* Enable=ca8nma 584 IRQ=mmen8f">dev);
10e1.c#L593" id="L5" id="L6p.c#L602" id* on t> 602    1062nd/is8l101" class="lineeeeeeeee" 101" >10e2is79sscapne" name="L492">dono8nd/_write_unsaf/9s81ss91pe.c#L637" id_write_unsaf/spin_unlGA_INTENA_REG9s81ss91pe.c#L6GA_INTENA_REG.c#Lea0x8ockss=wMA1f">l, _irqrestore" clas1063nd/is8l10ef=f="_Nrruct 1#L514"eee10ef=>10ef">l, _irqrestore" class="=hicode=c10e4nd/is8l10so8nd/is86sscape.c#L533"10so8>10e4o7nd/is79 630{
 6418 id="L6line"83>ssca7590"8 590789flags;
 6l, _irqrestore" clasline"633"> 633  MHz_unlock_irqr1065nd/is8l10s8 &= 0xf;
);
< if="+cmmen8f">dev);
10e01isubmentce2L602="comsupporL602" id* on t> 602    1078nd/is8l10="so8nd/is869scape.c#L5810="s>10="o7nd/is79 630{
);
spin_unlockss=wss_createt_host_mo[loccreate_mpu401nl9s81ss91pe.c#L61nlaa h],02    1071nd/is8l10a href="so8nd/is87sscape10a h>10=_irq4stl>s->card;dmr{
card;dmr2t_mo[loccreate_mpu401nl9s81ss91pe.c#L61nlaa h]1" /is7/sscape.c#L639" id="Le.cc1072nd/is8l10ef="+code=flags" 8 class10ef=>10=2s=wssstruct torecard" class=hicct m8">f9ags;
10= it 5 s8ss="9omme890> 571}
,  621
m8">f9ags;
10=puode=card" classmpuf"1" id24    3sscapeass=629" id="L6pe_midi_put" cla/a>);
< if="+ca w0x3>s7;lx, IRQ=3>s7;db5L471" id="L47aess="sref">m8">f9ags;
set_host_mode_unsafe 571}
        spin_unlockss=wss_createt_host_mo[loccreate_mpu401nl9s81ss91pe.c#L61nlaa h]1" /is7/sscape.c#L639" id="Le.cc1076nd/is8l10e.c#L624e.c#L626" id="L610e.c>10=ss="lin7;he 8ound789p    card;preode=e_dmr+code=flags" c8="sref">m8x = 121077nd/is8l10d="L628" class=mma1ref">10d=">10=     = spin_unlocWSS_HWSH101re>10=8ags" c8sass="sre8   return strcpy8">c="sref">8eL471" id="L471" /is7/sscape.c#L639" id="Le.cc10=9nd/is8l107{
ass="sref">locksh+rt75">ass="lue" class="erec75">ass="sref">lock75">10ndo7nd/is79 630{
ass="sref">lock=val75">ass="lsizeofe="L821"9="L821"#L587" id="L5="L592" class=37" class="lin8las9==val75">ass="sref">lock=val75">ass=)aess="sref">m8">f9ags;
10n_irq4stl>s->8">c3>s7;sma w0x3>s7;lx, IRQ=3>s7;d, DMA1=3>s7;d, DMA2=3>s7;db5L471" id="L47aess="sref">m8">f9ags;
10n11111="L558" cla clas"ue" class="erec75">ass="sref">lock75">m8">f9ags;
uin10=ui>10nimes5 classCINFO" cr" ue" class="erec=o8nd/9s81ss91pe.c#L637" id="L637" class="lin8las9=7sscape.c#L624e9m9me="L609"lass="line" name="7;dmrerr" class="8" ndmres=wsalue" class="erec=o8nd/9s81ss91pe.c#L637" id="L637" class="lin8las9=7sscape.c#L624e9m9me="L609"lass="line" name="7;dmr2ef8f">card;dmr2t_mo1" /is7/sscape.c#L639" id="Le.cc1084nd/is8l10582
 10n5nd/is8l104" cla 1#L514"eeeeeeeeee104" >10n="sre#def4"e(card;oIDI_DEVNUMmes5 c00         10n6nd/is8l10 cl" 1#L514"eeeeeeeeeeee10 cl>10nss="lin7;he 8s616{
k9tl);
 633    struct <_mode_unsafe10n7nd/is8l10 id="L536" cla 1#L514"ee10 id>10nass=pcmstruct siVIV"nsig  if (spin_unloc10rem>10n"line" namerSCAPE_VIV" class="sref">srSCAPE_VIV"nsig  if ( 1091nd/is8l10ss="samentce_CLOCKf">l, 10ss=>10__irq4stl>s->{
m8">f9ags;
{
card;oIDI_DEVNUMmes5alue" class="erect <0        m8">f9ags;
eref">spin_unloc10mce>10_imes5 classCINFO" cr" cla:s="comme=ebled, ring">&sscape.c#L605" mpu_irq9s81ss91pe.c#L6mpu_irqt_mo[loccreate_mpu401nl9s81ss91pe.c#L61nlaa h]1" /is7/sscape.c#L639" id="Le.cc1094nd/is8l10hicct  610hic>10_puode=card" classmpuf"1" id24torecard" class=hicct m8">f9ags;
10_="sref">set_host_mode_unsafe 571}
,  621
sm8">f9ags;
set_host_mode_unsafe mme=ebled, ring0yref">8">c"PU-40e< if="+ca w0x3>s7;lxb5L471" id="L47aess="sref">m8">f9ags;
10_     571}
        10_MPU401>snd>t;card;preode=e_dmr+code=flags" c8="sref">m8x = 121099nd/is8l10e = scap10e10_"line" namerSCAPE_VIV" class=e_unsafe" ENODEVtype =  = scap11o8n>110uct <0         11o1nd/is8l11os="samentce_CLOCKf">l, 11os=>11o id="L4t_mode_unsafe"omme890> mme=ebled, rausecwe mg  if (eref">spin_unloc11oce>110S4231 works only6in CS4248 5L5pc#Lbidddddddddddddddd* on t> 602    11o4nd/is8l11oicct  611oic>11opuode=card" classmpufomme890> {
ret;
 6l, _irqrestore" clasline"633"> 633  MHz_unlock_irqr11o5nd/is8l11o 8ref="+code=flags" c7;11o 8>110="sref">set_host_mode_unsafe<;
lockmidi_vol2sscapg0"633"> 633  MHz_unlock_irqr11o6nd/is8l11o.c#L624e..c#L584" 8d="L11o.c>11oss="lin7;he 8ound789p_unsafe<;
l, _irqrestore" clas11o7nd/is8l11oclas=u0spin_unlocWSS_HW11ocl>11o     6l, _irqrestore" clas11o8nd/is8l11o"s href="so8nd/is8/ssca11o"s>110MPU401>snd>t;l, _irqrestore" clas11o9nd/is8l11o = scap11o11of">l, _irqrestore" cl444444444444444444444444444444445" class="lin8lho8nd/9s81ss91pe.c#L637" id="L637" class="lin8las9=midi_volass="sref">lockmidi_vol2sscl, _irqrestore" clas1118nd/is8l11fo" classhrc ode=ct 11fo   ;
l, _irqrestore" clas1111nd/is8l11re" clas=u0sp>spin_unloc11re">111_irq4stl>s->;
l, _irqrestore" clas1112nd/is8l11="s href="so8nd/is8/ssca11="s>11111111="L558" cla clas"ere=val0{
l, _irqrestore" clas1113nd/is8l11/a> = scapea11/a>>111imes5 classCINFO" cr" cla:s="comme=ebled, ring">&=val0{
lockmidi_vol2sscl, _irqrestore" clas1114nd/is8l11ass=mpu401ref">spin_unlo11ass>11fpuode=card" classmpuf"1" id240{
l, _irqrestore" clas1115nd/is8l11e.c#L629" id="L558" clas11e.c>111="sref">set_host_mode_unsafelassmpuf"1" id240{
l, _irqrestore" clas1116nd/is8l11,
;
l, _irqrestore" clas11f7nd/is8l11609"lass="line" name="7;11609>111    l, _irqrestore" clas1118nd/is8l11nd/is8l>typeme="L609"las11nd/>111MPU401>snd>t;l, _irqrestore" clas1119nd/is8l11=uinfo" class="sref">uin11=ui>1119ass=pcmstruct  63211ass>112="sref">s->l, _irqrestore" clas11a1nd/is8l11<, _irq4stl>spin_unlocks11<, >11aomentce_CLOCKclas=u0xhref="+code=lock" class=g0|  xc; 6418 id="L6line"83>ssca7590"8 590789flags;
 6l, _irqrestore" clasline"633"> 633  MHz_unlock_irqr1122nd/is8l119s82ss9ape.c#L5611111111119s8>11a         = lo name="L575"> 5711=rq>112so7nd/is79 63e_unsafe" ENODEVtype =  633  > = r11e=">112ict <0         11a5nd/is8l11aw  632   11aw >1125o7nd/is79 630mme=ebled, rausecwe mg  if ();
, 112eeeeee" to ges=lassplaybackmldev);
 584 ca8nde=erme="L3>sscs L471" d9flruclagL471" id="L47ess="sref">m8">f9ags;
dev);
,
>113f4231 works only6in CS4248 5L5pc#Lbi* on t> 602    1131nd/is8l1132"> 632raw 1131is79sscapne" name="L492">do#L587" id="L5="L592" class=37" class="lin8las9=privass=fre/9s81ss91pe.c#L6privass=fre/="+code=err" class="8" o>       =fre/9s81ss91pe.c#L6 o>       =fre/+code=flags" c8="sref">m8x = 121132nd/is8l11"> 628staopet_in"L6f11"> >11>890flags;
 628staopet_out"L6f11> 6>11>ss=wssstruct returng0"633"> 633  MHz_unlock_irqr11>4nd/is8l11e_f">iass="sref">s113ict <0         11>5nd/is8l11struct , 11>Tan9in href="+code=spreode=e_dmref8f">card;preode=e_dmr+cod8nd/is87sscape.c#L56111111111br11>6nd/is8l11e_mpu401ref">spin_unloci11e_m>113/is79sscapne" name="L492">dofre/_dmref8f">card;fre/_dmrcard;dmr1138f">9ctl)
oL621" i id="L6lipreode=e_84">oL9nd/is8l1137
11ero7nd/is79 630{
->811eS4231e_unsafe" ENODEVtype = 114ict <0         1145nd/is8l11#L574" id="L574" classis11#L5>114789sion);
11e/is79static int}
{
);
m8">f9ags;
11401isubmentce2L602="comsupporL602" id*6Mak"L6uref"ef"erefgiven ALL ofica8soca8r parlas584sen8f">dev);
spin11628>115f4231 works only6in CS4248 5L5pc#Lbi* on t> 602    1151nd/is8l11ma2f">lo name="L575"> 5711ma2>1161is79sscapne"torecard" class=hict <0        );
 633  > = r11e=">115         633  MHz_unlock_irqr1153nd/is8l11i_put" class=wssref">spi11i_p>115f">l, _irqrestore" class="=hicode=c1154nd/is8l11_fw);
115="sref">set_host_lass="lin8las9=mpu_irq9s81ss91pe.c#L6mpu_irqt_mo[loccreate_mpu40i9s81ss91pe.c#L6i.c#L]ip86sscape.c#L605" SNDRV_AUTO_IRQ9s81ss91pe.c#L6SNDRV_AUTO_IRQo7nd/|| _irqrestore" class="=hicode=c1156nd/is8l11TECTct , 115ss="lin7;he 8ound="L821"9="L821"dmref8f">card;dmrm8">f9ags;
 633116     621"> 6>
 6s="less="sref">m8">f9ags;
sm8">f9ags;

l, _irqrestore" cl4444444ss="sref">ss-> 633  MHz_unlock_irqr1161nd/is8l1100" class="lineeeeeeeee"1100">1161 id="L-t_mode_unsafe" ENODEVtype = 116890flags;
116ss=wssstruct returng1"633"> 633  MHz_unlock_irqr1164nd/is8l11so8nd/is86sscape.c#L533"11so8>11e4o7nde_unsafe" ENODEVtype = }
{
);
m8">f9ags;
 633  MHz_unlock_irqr1169nd/is8l11"L5breakchar 1169PU401>snd>t;flrucl R{
       9s81ss91pe.c#L6 o>        633  MHz_unlock_irqr1178nd/is8l11="so8nd/is869scape.c#L5811="s>11="o7nd/is79 63int 633  MHz_unlock_irqr1171nd/is8l11a href="so8nd/is87sscape11a h>117aass=pcmstruct 1172is79sscapne" name="L492">doret621" i id="L6liret="L6ode=err" class="8"  i9#L58_c8lass7" id="L5="L592  i9#L58_c8lassspin_unlo87" id="L5="L592idspin_unlTHIS_MODULE9s81ss91pe.c#L6THIS_MODULE.c#Less=wMA1f">l, _irqrestore" clas11=3nd/is8l11href="+code=new_val" cl811hre>11= it 5 s8ss="9omme890>>>>>>>>>>>>>>>sizeofeflrucl R{
       9s81ss91pe.c#L6 o>       1174o7nd/is79 63torecard" class=hicret621" i id="L6liret="L6oass="li /is7/sscape.c#L639" id="Le.cc11=5nd/is8l11har set_host_modereturngcard" class=hicret621" i id="L6liret="L6"633"> 633  MHz_unlock_irqr1176nd/is8l11e.c#L624e.c#L626" id="L611e.c>11=ss="l633"> 633  MHz_unlock_irqr1177nd/is8l11d="L628" class=mma1ref">11d=">117lags" c8sass="sre8   return so8nd/9s81ss91pe.c#L637" id="L6ape.c#L588" id="L63" i#L58_ o>       9s81ss91pe.c#L63" i#L58_ o>       spin_unlocWSS_HWSH111re>11=8ags" c8sass="sre8   return so8nd/9s81ss91pe.c#L637" id="L637" class="lin8las9="sre8">k9tl);
 633  MHz_unlock_irqr1179nd/is8l117{
11ndo7nd/is79 630{
card;dmr 633  MHz_unlock_irqr1181nd/is8l11idi_put" class=pcmass="s11idi>1181is79sscapne" name="L492">do  i9#L58_3et_1nl9s81ss91pe.c#L6  i9#L58_3et_1nluin11=ui>11nimes5 classCI name="L492">doret621" i id="L6liret="L6ode=err" class="8"c8lass=so8nd/9s81ss91pe.c#L6c8lass=so8nd/1184o7nd/is79 63torecard" class=hicret621" i id="L6liret="L6oass="li /is7/sscape.c#L639" id="Le.cc11n5nd/is8l114" cla 1#L514"eeeeeeeeee114" >118="sref">set_host_mode     633  MHz_unlock_irqr11n6nd/is8l11 cl" 1#L514"eeeeeeeeeeee11 cl>118ss="l633"> 633  MHz_unlock_irqr11n7nd/is8l11 id="L536" cla 1#L514"ee11 id>118lags" c8sass="sre8   return ret621" i id="L6liret="L6ode=err" class="8"  i9#L58_84"> 5849s81ss91pe.c#L6  i9#L58_84"> 584m8">f9ags;
spin_unloc11rem>11n"line" namerSCAPE_VIV=err" class="8"  i9,  621
s 584 de=erme="Lb5L471" id="L471" /is7/sscape.c#L639" id="Le.cc1198nd/is8l11_unlo ode=uinfo" class="11_un>119,it 5 s8ss="9omme890>     633  MHz_unlock_irqr1191nd/is8l11ss="samentce_CLOCKf">l, 11ss=>1191 id="L-t_mode_unsafe" ENODEVtype = do1nl_3et_1rv="so9s81ss91pe.c#L61nl_3et_1rv="sospin_unloc11mce>119ss=wssstruct returng0"633"> 633  MHz_unlock_irqr1194nd/is8l11hicct  611hic>119ict <0         1195nd/is8l11a 8ref="+code=flags" c7;11a 8>119Tan9in href="+code=spreode=e_#L587" id="L5="L592preode=e_#L58="L68nd/is87sscape.c#L56111111111br1196nd/is8l11e.c#L624e..c#L584" 8d="L11e.c>119/is79sscapne" name="L492">do  i9#L58_fre/9s81ss91pe.c#L6  i9#L58_fre/ 633  MHz_unlock_irqr11_8nd/is8l11="s href="so8nd/is8/ssca11="s>11_MPU40e_unsafe" ENODEVtype =  = scap11e1199ass=pcmstruct {
);
l, 12os=>12o id="7ess="sref">m8">f9ags;
don i9#L58_fre/9s81ss91pe.c#L6  i9#L58_fre/ = 0;
eref">spin_unloc12oce>120imes5 classCI name="L492">do1nl_3et_1rv="so9s81ss91pe.c#L61nl_3et_1rv="so = 0;
 612oic>12opuode=card" creturng0"633"> 633  MHz_unlock_irqr12o5nd/is8l12o 8ref="+code=flags" c7;12o 8>120="sree_unsafe" ENODEVtype =  633  MHz_unlock_irqr12o7nd/is8l12oclas=u0spin_unlocWSS_HW12ocl>12o    <#def4"e(sm8">f9ags;
120/span>);
l,static flrucl R{
 = 0;
 = 0;
m8">f9ags;
12fo   }
de=err" class="8"  i9 7" id_matchl, _irqrestore" clas1211nd/is8l12re" clas=u0sp>spin_unloc12re">121_irq4stl>s}
de=err" class="8"  i9 7" id_prob/9s81ss91pe.c#L6  i9 7" id_prob/l, _irqrestore" clas1212nd/is8l12="s href="so8nd/is8/ssca12="s>12111111="L558" .s571}
de=err" class="8"p_ ifex50_cape.c#L624e9m9mp_ ifex50_cm8">f9ags;
 = scapea12/a>>121imes5 classCI"mme=ebled, rausecwe mg  FIXME: suspe">fresumei* on t> 602    1214nd/is8l12ass=mpu401ref">spin_unlo12ass>12fpuode=card" c.s571}
 = 0;
de7ess="sref">m8">f9ags;
121="sref">set_host_mode.s571}
 = 0;
de=err" class="8"DEV_NAM.9s81ss91pe.c#L6DEV_NAM.s="less="sref">m8">f9ags;
,
m8">f9ags;
 633  MHz_unlock_irqr1218nd/is8l12nd/is8l>typeme="L609"las12nd/>121/span>);
uin12=ui>1219ass=#ifdef40{
);
 63212ass>122uct }
m8">f9ags;
12a        retas571}
        );
lo name="L575"> 5712=rq>122 it 5 s8ss="9omme890>++loccreate_mpu40i9s81ss91pe.c#L6i.c#L"633"> 633  MHz_unlock_irqr1224nd/is8l12e="L633"> 633  > = r12e=">122puode=card" creturngloccreate_mpu40i9s81ss91pe.c#L6i.c#L"633"> 633  MHz_unlock_irqr1225nd/is8l12aw  632   12aw >122="sree_unsafe" ENODEVtype = );
 633  MHz_unlock_irqr1227nd/is8l12"erect , 1228f">9ctl)
}
{
)
l, _irqrestore" cl44444444444444444444444confl flrucl R{
);
,
m8">f9ags;
 632raw 1231is79sscapne"static int 633  MHz_unlock_irqr1232nd/is8l12"> 628staopet_in"L6f12"> >1232is79sscapne"strucl R{
 633  MHz_unlock_irqr1233nd/is8l12> 628staopet_out"L6f12> 6>12>ss=wssstruct flrucl R{
 633  MHz_unlock_irqr12>4nd/is8l12e_f">iass="sref">s1234s=wssstruct flrucl R{
       9s81ss91pe.c#L6 o>        633  MHz_unlock_irqr12>5nd/is8l12struct , 123="sref">set_hint 633  MHz_unlock_irqr12>6nd/is8l12e_mpu401ref">spin_unloci12e_m>123ss="l633"> 633  MHz_unlock_irqr12>7nd/is8l12k, 
dev);
124f4231 works only6in CS4248 5L5pc#Lbi* on t> 602    1241nd/is8l12s8/sscape.c#L626" id="L612s8/>1241is79sscapne" name="L492">doidx9s81ss91pe.c#L6idx="L6odes571}
doidx9s81ss91pe.c#L6idx="L61" /is7/sscape.c#L639" id="Le.cc12e2nd/is8l12is84sscape.c#L600" id="L12is8>12e2s=wssstruct torecard" class=hicidx9s81ss91pe.c#L6idx="L6oa" c="d/9s81ss91is87ssNDRV_CARDS9s81ss91pe.c#L6SNDRV_CARDS.c#L1on);
returng-d/9s81ss91is87sENOSPC9s81ss91pe.c#L6ENOSPC="L6"633"> 633  MHz_unlock_irqr1244nd/is8l12533" id="L533" classCrea12533>124ict <0         1245nd/is8l12#L574" id="L574" classis12#L5>1245o7nd/is79 630mme=ebled, rausecwe mg  if (124 14.31818 MHz, becausecwe mus  ses=lt Checkli1" iwe stillihav"oroom for anoca8r de=erme="Lcmmen8f">dev);
124eeeeee" to ges=lassplaybackml 602    1248nd/is8l12 it 5 s8ename="L68a> <12 it>1248ags" c8sass="sre8   return 1nl9s81ss91pe.c#L61nlaa hodes571}
}
1249s=wssstruct tore!a href="+code=s1nl9s81ss91pe.c#L61nlaa h1on);
spin12628>125="sref">s-> 633  MHz_unlock_irqr1251nd/is8l12ma2f">lo name="L575"> 5712ma2>125aass=pcmstruct  633  > = r12e=">1252s=wssstruct tore!a href="+code=spnp_is_acti"L590"8class="linpnp_is_acti"Lm8">f9ags;
spi12i_p>125 it 5 s8ss="9omme890>torecard" class=hictnp_acti"ass=1nl9s81ss91pe.c#L6pnp_acti"ass=1nlm8">f9ags;
);
 621"> 6>
 6s="l_ss="sref">s125="sref">set_host_-> 633  MHz_unlock_irqr1256nd/is8l12TECTct , 125ss="lin7;he 8ounddddde_unsafe" ENODEVtype =  633125     = 
l, _irqres0mme=ebled, rausecwe mg  if (126f4231 works only6in CS4248 5L5pc#Lbi* C8lass a new ALSA de=erme="Lc424ry,=in anticipat>oL1261 id= works only6in CS4248 5L5pc#Lbi* of 641" iing our h="Lwarefmmen8f">dev);
1262al" bmentce2L602="comsupporL602" id* on t> 602    1263nd/is8l12ef=f="_Nrruct 1#L514"eee12ef=>126imes5 classCI name="L492">doret621" i id="L6liret="L6ode=err" class="8"  i9#L58_c8lass7" id="L5="L592  i9#L58_c8lassspin_unlo87" id="L5="L592idspin_unlTHIS_MODULE9s81ss91pe.c#L6THIS_MODULE.c#Less=wMA1f">l, _irqrestore" clas1264nd/is8l12so8nd/is86sscape.c#L533"12so8>1264o7nd/is79 633333333333333333333333sizeofeflrucl R{
       9s81ss91pe.c#L6 o>       1265s=wssstruct tore name="L492">doret621" i id="L6liret="L6oass="li /is7/sscape.c#L639" id="Le.cc1266nd/is8l12 hc ode=uinfo" class="sh12 hc>126ss="lin7;he 8oundddddreturngcard" class=hicret621" i id="L6liret="L6"633"> 633  MHz_unlock_irqr1267nd/is8l12 class="sa hrc ode=ct 1268f">9ctl)
       9s81ss91pe.c#L63" i#L58_ o>       1269ass=pcmstruct dev);
1272al" bmentce2L602="comsupporL602" id* on t> 602    12=3nd/is8l12href="+code=new_val" cl812hre>12= it 5 s8ss="9tore!a href="+code=sflrncmcape.c#L624e9m9mflrncmcs1274o7nd/is79 6333333333"sre8   return so8nd/9s81ss91pe.c#L637" id="L637" class="lin8las9="sre8">k9tl);
12=="sref">set_helse /is7/sscape.c#L639" id="Le.cc12=6nd/is8l12e.c#L624e.c#L626" id="L612e.c>127ss="lin7;he 8ounddddd"sre8   return so8nd/9s81ss91pe.c#L637" id="L637" class="lin8las9="sre8">k9tl);
12d=">1278f">9ctl)
spin_unlocWSS_HWSH121re>1278ags" c8sass="mme=ebled, rausecwe mg  if ({
dev);
128f4231 works only6in CS4248 5L5pc#Lbi* on t> 602    1281nd/is8l12idi_put" class=pcmass="s12idi>1281is79sscapne" name="L492">dop <0        }
        l, _irqrestore" clas1282nd/is8l12apcmstruned long 1282is79sscapne" name="L492">doirq9s81ss91pe.c#L6irqt_mo[loccreate_mpu40idx9s81ss91pe.c#L6idx="L6]odes571}
l, _irqrestore" clas1283nd/is8l12=uinfo" class="sref">uin12=ui>12nimes5 classCI name="L492">dompu_irq9s81ss91pe.c#L6mpu_irqt_mo[loccreate_mpu40idx9s81ss91pe.c#L6idx="L6]odes571}
l, _irqrestore" clas1284nd/is8l12582
card;dmr}
card;pnp_1mr 633  MHz_unlock_irqr12n5nd/is8l124" cla 1#L514"eeeeeeeeee124" >1285s=wssstruct tore name="L492">doso8nd/9s81ss91pe.c#L637" id="L637" class="lin8las9="sre8">k9tl);
m8">f9ags;
128ss="lin7;he 8ounddddd"sre8   return 1mr2ef8f">card;dmr2}
card;dmr 633  MHz_unlock_irqr12n7nd/is8l12 id="L536" cla 1#L514"ee12 id>128    }
        l, _irqrestore" clas1288nd/is8l12; 0) {
12n name="7;68"=}helsen7ess="sref">m8">f9ags;
spin_unloc12rem>12n"line" namerSCAPE_VIV=err" class="8"o8ndp <0                l, _irqrestore" clas1298nd/is8l12_unlo ode=uinfo" class="12_un>129,it 5 s8ss="9omme890>"sre8   return 1mr2ef8f">card;dmr2}
card;pnp_1mrl, _irqrestore" clas1291nd/is8l12ss="samentce_CLOCKf">l, 12ss=>1291 id="L-t_mode_unsafe" ENODEVtype = do  i9#L58_3et_1nl9s81ss91pe.c#L6  i9#L58_3et_1nll, _irqrestore" clas1293nd/is8l12mce_dow>eref">spin_unloc12mce>129f">l, _irqrestore" class="=hicode=c1294nd/is8l12hicct  612hic>1294o7nd/is79 63="L821"9="L821"ret621" i id="L6liret="L6ode=err" class="8"c8lass=so8nd/9s81ss91pe.c#L6c8lass=so8nd/1295s=wssstruct tore name="L492">doret621" i id="L6liret="L6oass="li /is7/sscape.c#L639" id="Le.cc1296nd/is8l12e.c#L624e..c#L584" 8d="L12e.c>129ss="lin7;he 8ounddddd     633  MHz_unlock_irqr1297nd/is8l12 clas=u0spin_unlocWSS_HW12 cl>1298f">9ctl)
1298ags" c8sass="sre8   return ret621" i id="L6liret="L6ode=err" class="8"  i9#L58_84"> 5849s81ss91pe.c#L6  i9#L58_84"> 584doret621" i id="L6liret="L6oass="lin7ess="sref">m8">f9ags;
 = scap13o8n>130,it 5 s8ss="9omme890>"sre8   return   i9,  621
s 584 de=erme="Lb5L471" id="L471" /is7/sscape.c#L639" id="Le.cc13o1nd/is8l13os="samentce_CLOCKf">l, 13os=>130omentce_CLOCKclas=u0x     633  MHz_unlock_irqr13o2nd/is8l13ounlo ode=uinfo" class="13oun>1302is79sscapne"e_unsafe" ENODEVtype = eref">spin_unloc13oce>130f">l, _irqrestore" class="=hicode=c13o4nd/is8l13oicct  613oic>1304o7nd/is79 63="L821"9="L821"pnp_s" i#L58_1rv="so9s81ss91pe.c#L6pnp_s" i#L58_1rv="so}
1305s=wssstruct ++loccreate_mpu40idx9s81ss91pe.c#L6idx="L6" /is7/sscape.c#L639" id="Le.cc13o6nd/is8l13o.c#L624e..c#L584" 8d="L13o.c>130ss="lin7;he 8returng0"633"> 633  MHz_unlock_irqr13o7nd/is8l13oclas=u0spin_unlocWSS_HW13ocl>1308f">9ctl)
130/spann href="+code=spreode=e_#L587" id="L5="L592preode=e_#L58="L68nd/is87sscape.c#L56111111111br13o9nd/is8l13o = scap13o1309o7nd/is79 630{
13fo    633  MHz_unlock_irqr1311nd/is8l13re" clas=u0sp>spin_unloc13re">131_irq4e_unsafe" ENODEVtype = {
{
spin_unlo13ass>13fpuode7ess="sref">m8">f9ags;
131="sref">set_h0{
,
dopnp_s" i#L58_1rv="so9s81ss91pe.c#L6pnp_s" i#L58_1rv="so}
131/span>);
uin13=ui>131f">l,static flrucl R{
 = 0;
 = 0;
m8">f9ags;
 63213ass>132o   }
m8">f9ags;
spin_unlocks13<, >132_irq4stl>s}
 = 0;
sm8">f9ags;
13211111="L558" .s571}
 = 0;
m8">f9ags;
lo name="L575"> 5713=rq>132 it 5 s8ss="9.s571}
m8">f9ags;
 633  > = r13e=">132puode=card" c.s571}
m8">f9ags;
 632   13aw >132="sree" /is7/sscape.c#L639" id="Le.cc1326nd/is8l13ags);
 633  MHz_unlock_irqr1327nd/is8l13"erect , 1328f">9#endifI"mme=ebled, rausecwe mg  CONFIG_PNPi* on t> 602    13a8nd/is8l13_MPU401uinfo" class="sMP13_MP>132/span>);
l,static int}
,
>133f42317ess="sref">m8">f9ags;
 632raw 1331is79sscapne"int 628staopet_in"L6f13"> >133890flags;
 628staopet_out"L6f13> 6>133imes5 classCI name="L492">doct  584_drivn = 0;
 584_drivn< = 0;
iass="sref">s1334s=ws#ifdef40{
);
spin_unloci13e_m>133ss="lin7;he 8ounddddd"sre8   return nd/_84"> 584e87" id="L5="L592id/_84"> 584e88" c9de1"633"> 633  MHz_unlock_irqr13>7nd/is8l13k, 9ctl)
 584_#L58_1rivn = 0;
 584_#L58_1rivn< = 0;
1339s=wssstruct tore!a href="+code=sct 134,it 5 s8ss="9omme890>"sre8   return snp_re"> 584e87" id="L5="L592snp_re"> 584e88" c9de1"633"> 633  MHz_unlock_irqr1341nd/is8l13s8/sscape.c#L626" id="L613s8/>134aass=pcmstruct  584e87" id="L5="L592id/_84"> 584e88" ci /is7/sscape.c#L639" id="Le.cc1343nd/is8l13ass="lin8e->8134 it 5 s8ss="9omme890>"sre8   return ct  633  MHz_unlock_irqr1344nd/is8l13533" id="L533" classCrea13533>134ict <#endif633"> 633  MHz_unlock_irqr1345nd/is8l13#L574" id="L574" classis13#L5>1345o7nd/is79 63returngcard" class=hicct 134 14.3} /is7/sscape.c#L639" id="Le.cc13e7nd/is8l13);
9ctl)
 <13 it>1341349s=ws7ess="sref">m8">f9ags;
spin13628>135="sre#ifdef40{
);
lo name="L575"> 5713ma2>1351s=wssstruct torecard" class=hicsnp_re"> 584e87" id="L5="L592snp_re"> 584e88" ci /is7/sscape.c#L639" id="Le.cc1352nd/is8l13e="L633"> 633  > = r13e=">1352s=wssstruct omme890>"sre8   return snp_unre"> 584_#L58_1rivn = 0;
 584_#L58_1rivn< = 0;
spi13i_p>135 it 5 s8ss="9torecard" class=hicid/_84"> 584e87" id="L5="L592id/_84"> 584e88" ci /is7/sscape.c#L639" id="Le.cc1354nd/is8l13_fw);
 633  MHz_unlock_irqr1355nd/is8l13 class="sa hrc ode=ct 135="sref">set_host_card" class=hicid/_unre"> 584_drivn = 0;
 584_drivn< = 0;
 6331358f">9ctl)
135/spann href="+code=smodule_=L509" cla s="line"module_=L50
>135f">l,n href="+code=smodule_ex509" cla s="line"module_ex50lx4@x10ux.no="L6.
 /div>
lx4.x10ux.no kindly ho 58dobyi/is7/sscahttp://www.4e8pill-x10pro.no">Re8pill L10pro AS="L6aeprovider of L10ux4confuliing and operat>oLs serlicesfsince 1995. /div>