lkml.org 
[lkml]   [1999]   [Dec]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectSBS450-10704 SCSI Ultra-Wide on Sun 4/670MP qlogicpti.c problem

I managed to get this disk controller to work. The "fix" that I did to
get it to work though would probably break other architectures but I think
that probably all that is required is some refinement of one bit of #ifdef'd
code.

In the file qlogicicpti.c lines 462 through 480 we have:

#if !defined(MODULE) && !defined(__sparc_v9__)
if (sparc_cpu_model != sun4d) {
dvma_addr = (unsigned long) mmu_lockarea((char *)&risc_code[0],
(sizeof(u_short) *
risc_code_length));
param[0] = MBOX_LOAD_RAM;
param[1] = risc_code_addr;
param[2] = (dvma_addr >> 16);
param[3] = (dvma_addr & 0xffff);
param[4] = (sizeof(u_short) * risc_code_length);
if(qlogicpti_mbox_command(qpti, param, 1) ||
(param[0] != MBOX_COMMAND_COMPLETE)) {
printk(KERN_EMERG "qlogicpti%d: Firmware dload failed,
I'm bolixed!\n",
qpti->qpti_id);
restore_flags(flags);
return 1;
}
mmu_unlockarea((char *)dvma_addr, (sizeof(u_short) *
risc_code_length));
} else
#endif

...

And then following that:

/* We need to do it this slow way always on Ultra, SS[12]000. */
for(i = 0; i < risc_code_length; i++) {
param[0] = MBOX_WRITE_RAM_WORD;
param[1] = risc_code_addr + i;
param[2] = risc_code[i];
if(qlogicpti_mbox_command(qpti, param, 1) ||
param[0] != MBOX_COMMAND_COMPLETE) {
printk("qlogicpti%d: Firmware dload failed, I'm
bolixed!\n",
qpti->qpti_id);
restore_flags(flags);
return 1;
}
}

Well, apparently on a 4/670MP with Ross Hypersparc, we need to do it the
slow way too, because removing the above code so that it always used this
method fixed the problem. The SCSI card initializes fine and it's been
grinding on news all day without an error.

Hypersparc is version 8, not version 9, so I don't know if you could just
add || defined (__sparc8__)? I.e., I don't know what gcc defines on Hypersparc
that would differentiate it from a machine with the old Ross or Cypress 40mhz
or TI 50mhz CPU's, or for that matter if the code would have worked had I had
those CPU's (since I don't I couldn't test it).

I'd really like to get this fixed so that each time I upgrade Linux kernel
I don't have to go in and hack that bit of code out of the driver, not that
it's a big deal but a whole bunch of little deals gets to be a PITA.




-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:55    [W:0.724 / U:0.068 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site