tech-kern archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: agp_nvidia port for review
Forgot to comment on these:
On Mon, Jun 8, 2026 at 1:50 AM Taylor R Campbell <riastradh%netbsd.org@localhost> wrote:
> > + u_int32_t initial_aperture; /* aperture size at startup */
> > [...]
> > + u_int32_t wbc_mask;
>
> Since this is effectively new code without an upstream (assuming it's
> going to be deleted in FreeBSD soon), use the standard C99 uint32_t
> types.
>
I kept u_int32_t to stay consistent with the other AGP drives,
agp_methods signatures use it.
For local variables I've already use uint32_t in nvidia_init_iorr(),
and I can do the same in the other methods.
>> + /* Wait no more than 3 seconds. */
>> + for (i = 0; i < 3000; i++) {
>> + wbc_reg = pci_conf_read(sc->as_pc, nsc->mc1_tag, AGP_NVIDIA_1_WBC);
>> + if ((nsc->wbc_mask & wbc_reg) == 0)
>> + break;
>> + else
>> + DELAY(1000);
> Seems like a very long time to wait in a DELAY loop? Wonder if this
> should be a preempt_point.
Good point, but lack technical understanding here.
I need to investigate on how to rewrite or improve this part. Advice
welcome if you already know what is the best way to do it or what to
look at.
Regards,
Andrius V
Home |
Main Index |
Thread Index |
Old Index