• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-R7000-V1.0.7.12_1.2.5/components/opensource/linux/linux-2.6.36/drivers/staging/wlan-ng/

Lines Matching refs:pda

106 struct pda {
154 struct pda pda;
170 static int read_cardpda(struct pda *pda, wlandevice_t *wlandev);
172 static int mkpdrlist(struct pda *pda);
175 struct s3plugrec *s3plug, unsigned int ns3plug, struct pda * pda);
264 /* clear the pda and add an initial END record */
265 memset(&pda, 0, sizeof(pda));
266 pda.rec[0] = (hfa384x_pdrec_t *) pda.buf;
267 pda.rec[0]->len = cpu_to_le16(2); /* len in words */
268 pda.rec[0]->code = cpu_to_le16(HFA384x_PDR_END_OF_PDA);
269 pda.nrec = 1;
276 if (read_cardpda(&pda, wlandev)) {
333 result = plugimage(fchunk, nfchunks, s3plug, ns3plug, &pda);
577 * pda buffer containing raw PDA bytes
585 int mkpdrlist(struct pda *pda)
588 u16 *pda16 = (u16 *) pda->buf;
591 pda->nrec = 0;
595 pda->rec[pda->nrec] = (hfa384x_pdrec_t *) &(pda16[curroff]);
597 if (le16_to_cpu(pda->rec[pda->nrec]->code) == HFA384x_PDR_NICID) {
598 memcpy(&nicid, &pda->rec[pda->nrec]->data.nicid,
605 if (le16_to_cpu(pda->rec[pda->nrec]->code) ==
607 memcpy(&rfid, &pda->rec[pda->nrec]->data.mfisuprange,
614 if (le16_to_cpu(pda->rec[pda->nrec]->code) ==
616 memcpy(&macid, &pda->rec[pda->nrec]->data.cfisuprange,
624 (pda->nrec)++;
631 "PDR data, exiting. %x %d\n", curroff, pda->nrec);
635 pda->rec[pda->nrec] = (hfa384x_pdrec_t *) &(pda16[curroff]);
636 (pda->nrec)++;
652 * pda Current pda data
659 struct s3plugrec *s3plug, unsigned int ns3plug, struct pda * pda)
678 for (j = 0; j < pda->nrec; j++) {
680 le16_to_cpu(pda->rec[j]->code))
686 if (j >= pda->nrec && j != -1) { /* if no matching PDR, fail */
694 if (j != -1 && s3plug[i].len < le16_to_cpu(pda->rec[j]->len)) {
730 memcpy(dest, &(pda->rec[j]->data), s3plug[i].len);
740 * Sends the command for the driver to read the pda from the card
741 * named in the device variable. Upon success, the card pda is
742 * stored in the "cardpda" variables. Note that the pda structure
748 * pda pda structure
755 int read_cardpda(struct pda *pda, wlandevice_t *wlandev)
764 msg.pda.did = DIDmsg_p2req_readpda_pda;
765 msg.pda.len = HFA384x_PDA_LEN_MAX;
766 msg.pda.status = P80211ENUM_msgitem_status_no_value;
775 memcpy(pda->buf, msg.pda.data, HFA384x_PDA_LEN_MAX);
776 result = mkpdrlist(pda);
1057 /* Send flashdl_write(pda) */